PHPackages                             castiron/webpackassets-plugin - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. castiron/webpackassets-plugin

ActiveOctober-plugin[Utility &amp; Helpers](/categories/utility)

castiron/webpackassets-plugin
=============================

Webpack hashed files in October CMS

2.0.3(3y ago)65.1k1[1 issues](https://github.com/castiron/webpackassets-plugin/issues)MITPHPPHP &gt;=5.4CI failing

Since May 18Pushed 2y ago10 watchersCompare

[ Source](https://github.com/castiron/webpackassets-plugin)[ Packagist](https://packagist.org/packages/castiron/webpackassets-plugin)[ Docs](https://github.com/castiron/webpackassets-plugin)[ RSS](/packages/castiron-webpackassets-plugin/feed)WikiDiscussions master Synced yesterday

READMEChangelogDependencies (1)Versions (14)Used By (0)

Webpack Assets in October CMS
-----------------------------

[](#webpack-assets-in-october-cms)

This plugin for OctoberCMS works in tandem with the node package `webpack-assets-manifest`() to include CSS, JS, and font assets in your site based on a JSON manifest file written to your assets directory. This will allow you to use hashed file names in your built files, and let October pick up the paths effortlessly.

In non-development environments (when the APP\_ENV environment variable doesn't equal "dev") these paths get cached so the JSON file isn't read on every request. This cache should be cleared as a part of the deploy process by running `php artisan cache:clear`.

### Installation

[](#installation)

```
composer require castiron/webpackassets-plugin

```

### Quick start

[](#quick-start)

This plugin provides a component called `webpackAssets`. Include the component in your view and then use the following to include the js/css/fonts (WOFF2 only) in your template (e.g. in a partial, layout, etc.):

```
[webpackAssets]
==

{{ webpackAssets.tag('unhashed_filename.woff2') | raw }}

{{ webpackAssets.tag('unhashed_filename.css') | raw }}
```

```
[webpackAssets]
==

{{ webpackAssets.tag('unhashed_filename.js') | raw }}
{{ webpackAssets.tag('webpack-dev-server.js') | raw }}
```

Keep in mind that there’s a performance trade-off to preloading too many font assets, so limit your use to only the highest-priority font assets. For the same reason, the plugin will only create tags for the WOFF2 font format. (See [“The Critical Request”](https://calibreapp.com/blog/critical-request/) and [“The Web Fonts: Preloaded”](https://www.zachleat.com/web/preload/) for more information.)

### Component options

[](#component-options)

`publicFolder` (default: "www")

If you are [using a public folder in OctoberCMS](https://octobercms.com/docs/setup/configuration#public-folder) (you should be!), specify it here. E.g. "www" or "public"

```
[webpackAssets]
publicFolder = public

```

`assetsFolder` (default: "assets")

The path to the folder, relative to your public folder, to which webpack is writing your assets. This corresponds to `output.path` from your webpack config.

```
[webpackAssets]
assetsFolder = assets

```

`manifestFilename` (default: "manifest.json", must be relative to assetsFolder)

```
[webpackAssets]
manifestFilename = files.json

```

Changelog
---------

[](#changelog)

### 2.0.3

[](#203)

- October 1.1 compatible

###  Health Score

34

—

LowBetter than 75% of packages

Maintenance17

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 50% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~240 days

Recently: every ~474 days

Total

10

Last Release

1171d ago

Major Versions

1.0.6 → 2.0.02018-05-10

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/334526?v=4)[Gabe Blair](/maintainers/gblair)[@gblair](https://github.com/gblair)

---

Top Contributors

[![lthurston](https://avatars.githubusercontent.com/u/202726?v=4)](https://github.com/lthurston "lthurston (3 commits)")[![kylepratuch](https://avatars.githubusercontent.com/u/13619388?v=4)](https://github.com/kylepratuch "kylepratuch (2 commits)")[![dananjohnson](https://avatars.githubusercontent.com/u/12454203?v=4)](https://github.com/dananjohnson "dananjohnson (1 commits)")

---

Tags

octobercmswebpackoctoberoctobercmswebpack

### Embed Badge

![Health badge](/badges/castiron-webpackassets-plugin/health.svg)

```
[![Health](https://phpackages.com/badges/castiron-webpackassets-plugin/health.svg)](https://phpackages.com/packages/castiron-webpackassets-plugin)
```

###  Alternatives

[rainlab/builder-plugin

Builder plugin for October CMS

17147.6k1](/packages/rainlab-builder-plugin)[rainlab/pages-plugin

Pages plugin for October CMS

12253.8k4](/packages/rainlab-pages-plugin)[rainlab/user-plugin

User plugin for October CMS

11955.0k15](/packages/rainlab-user-plugin)[rainlab/blog-plugin

Blog plugin for October CMS

17159.2k](/packages/rainlab-blog-plugin)[rainlab/translate-plugin

Translate plugin for October CMS

12768.5k10](/packages/rainlab-translate-plugin)[rainlab/sitemap-plugin

Sitemap plugin for October CMS

2282.4k1](/packages/rainlab-sitemap-plugin)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
