36 lines
817 B
Markdown
36 lines
817 B
Markdown
# October CMS Webpack Theme Boilerplate
|
|
|
|
==========
|
|
|
|
This is a starter theme for October CMS that includes:
|
|
|
|
- Webpack (using Laravel Mix)
|
|
- PostCSS
|
|
- Hot module reloading
|
|
|
|
To use it:
|
|
|
|
- [Install October CMS](https://octobercms.com/docs/setup/installation).
|
|
- Clone the repo in October's `themes` directory.
|
|
- Inside cloned directory run `npm install`.
|
|
- Install more packages using `npm install --save`.
|
|
- Require your installed packages in `src/js/app.js`.
|
|
- Run `npm run dev` (`npm run watch` to recompile when something changes, `npm run hot` to enable HMR).
|
|
- Run `npm run prod` to compile for production.
|
|
|
|
## To enable the Ajax framework
|
|
|
|
```sh
|
|
npm install jquery
|
|
```
|
|
|
|
Add framework tag to `layouts/default.htm`:
|
|
|
|
```
|
|
<script src="{{ this.layout.scripts }}"></script>
|
|
|
|
{% framework extras %}
|
|
|
|
{% scripts %}
|
|
```
|