Hey there,
I’m trying to set up a Vagrant box for development with Sage, however because of the way that folder syncing works, bud / webpack does not pick up the file changes.
Is there a quick way to set up polling in my bud.config.js?
I’ve tried the following:
.options.set(‘webpack.watchOptions.poll’, true)
However, this gives me an error when running yarn dev.
TypeError: app.entry(…).assets(…).watch(…).options.set is not a function
Here’s my entire bud.config.js for reference:
module.exports = async (app) => {
app
/**
* Application entrypoints
*
* Paths are relative to your resources directory
*/
.entry({
app: ['@scripts/app', '@styles/app'],
editor: ['@scripts/editor', '@styles/editor'],
})
/**
* These files should be processed as part of the build
* even if they are not explicitly imported in application assets.
*/
.assets('images')
/**
* These files will trigger a full page reload
* when modified.
*/
.watch('resources/views/**/*', 'app/**/*')
.options.set('webpack.watchOptions.poll', true)
/**
* Target URL to be proxied by the dev server.
*
* This should be the URL you use to visit your local development server.
*/
.proxy('http://kineepik.local')
/**
* Development` URL to be used in the browser.
*/
.serve('http://192.168.0.10:3000');
};