mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-11 03:41:12 +00:00
seafile-editor-master-dist
This commit is contained in:
21
frontend/config/WebpackDevServer.js
Normal file
21
frontend/config/WebpackDevServer.js
Normal file
@@ -0,0 +1,21 @@
|
||||
var webpack = require('webpack')
|
||||
var WebpackDevServer = require('webpack-dev-server')
|
||||
var config = require('./webpack.config.dev')
|
||||
|
||||
new WebpackDevServer(webpack(config), {
|
||||
publicPath: config.output.publicPath,
|
||||
hot: true,
|
||||
contentBase: '../assets',
|
||||
historyApiFallback: true,
|
||||
headers: {
|
||||
"Access-Control-Allow-Origin": "*",
|
||||
"Access-Control-Allow-Methods": "GET, POST, PUT, DELETE, PATCH, OPTIONS",
|
||||
"Access-Control-Allow-Headers": "X-Requested-With, content-type, Authorization"
|
||||
}
|
||||
}).listen(3000, '0.0.0.0', function (err, result) {
|
||||
if (err) {
|
||||
console.log(err)
|
||||
}
|
||||
|
||||
console.log('Listening at 0.0.0.0:3000')
|
||||
})
|
Reference in New Issue
Block a user