- Updates webpack config file
- Adds an option to watch/compile just the JS files with webpack
This commit is contained in:
@ -47,6 +47,10 @@ class RoboFile extends \Robo\Tasks {
|
|||||||
->run();
|
->run();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function watchJs() {
|
||||||
|
$this->_exec('./node_modules/webpack/bin/webpack.js --watch');
|
||||||
|
}
|
||||||
|
|
||||||
function compileAll() {
|
function compileAll() {
|
||||||
$this->compileJs();
|
$this->compileJs();
|
||||||
$this->compileCss();
|
$this->compileCss();
|
||||||
|
@ -6,6 +6,10 @@ var webpack = require('webpack'),
|
|||||||
|
|
||||||
baseConfig = {
|
baseConfig = {
|
||||||
context: __dirname,
|
context: __dirname,
|
||||||
|
watch: {
|
||||||
|
aggregateTimeout: 300,
|
||||||
|
poll: true
|
||||||
|
},
|
||||||
output: {
|
output: {
|
||||||
path: './assets/js',
|
path: './assets/js',
|
||||||
filename: '[name].js',
|
filename: '[name].js',
|
||||||
@ -84,7 +88,8 @@ config.push(_.extend({}, baseConfig, {
|
|||||||
'newsletters/newsletters.jsx',
|
'newsletters/newsletters.jsx',
|
||||||
'segments/segments.jsx',
|
'segments/segments.jsx',
|
||||||
'forms/forms.jsx',
|
'forms/forms.jsx',
|
||||||
'settings/tabs.js'
|
'settings/tabs.js',
|
||||||
|
'import/import.js'
|
||||||
],
|
],
|
||||||
form_editor: [
|
form_editor: [
|
||||||
'form_editor/form_editor.js',
|
'form_editor/form_editor.js',
|
||||||
|
Reference in New Issue
Block a user