Open vdeppe opened 4 years ago
This plugin doesn't serve your webpack assets. It handles livereload in apps that have their assets served by another process.
devServer
is for configuring webpack-dev-server which may be what you need.
Took me many days to make webpack-dev-server work in WordPress coz it needs the HTML file, but I can't. Finally this plugin works!
"webpack-livereload-plugin": "^3.0.1",
"webpack": "^5.33.2",
"webpack-cli": "^4.6.0",
new LiveReloadPlugin({ protocol: "http", hostname : "understraptest.local", appendScriptTag: true, })
Hello, I want to use the livereload-plugin in my webApp. But somehow it doesn't work. My Webapp should run on port 8080, which I have defined in devServer. Could you please check my file, which looks as follows?
`const CopyPlugin = require('copy-webpack-plugin'); var LiveReloadPlugin = require('webpack-livereload-plugin');
module.exports = { plugins: [ new LiveReloadPlugin() ], entry: { bundle: ['./app/app.js'] }, output: { path: __dirname + '/public', filename: 'app.js' }, module: { rules: [ { test: /.bpmn$/, use: 'raw-loader' } ] }, devServer: { port: 8080, }, plugins: [ new CopyPlugin({ patterns: [ { from: 'assets/', to: 'vendor/bpmn-js', context: 'node_modules/bpmn-js/dist/' }, { from: '/*.{html,css,png}', context: 'app/' }, ], }), ], mode: 'development', devtool: 'source-map' }; ` thanks and kind regards