我已經在Stephen Grider的ReduxSimpleStarter之上構建了一個web應用,這是一個反應簡化的樣板。它使用Webpack進行捆綁。現在我想在firebase上託管我的應用程序。當我這樣做時,捆綁不起作用,我只剩下一個簡單的index.html。託管與webpack捆綁在一起的web應用
難道有人請解釋我如何觸發未本地託管的應用程序的Webpack綁定?
這些文件可能是相關的,但我不確定。
//package.json
{
"name": "testapp",
"version": "0.0.0",
"description": "testapp",
"main": "index.js",
"scripts": {
"start": "node ./node_modules/webpack-dev-server/bin/webpack-dev-server.js"
},
"author": "",
"license": "ISC",
"devDependencies": {
"babel-core": "^6.2.1",
"babel-loader": "^6.2.0",
"babel-preset-es2015": "^6.1.18",
"babel-preset-react": "^6.1.18",
"webpack": "^1.12.9",
"webpack-dev-server": "^1.14.0"
},
"dependencies": {
"axios": "^0.9.1",
"babel-preset-stage-1": "^6.1.18",
"jquery": "^2.2.0",
"lodash": "^3.10.1",
"material-ui": "^0.14.4",
"react": "^0.14.3",
"react-dom": "^0.14.3",
"react-redux": "^4.0.0",
"react-tap-event-plugin": "^0.2.2",
"redux": "^3.0.4",
"redux-promise": "^0.5.1"
}
}
。
//webpack.config
module.exports = {
entry: [
'./src/index.js'
],
output: {
path: __dirname,
publicPath: '/',
filename: 'bundle.js'
},
module: {
loaders: [{
exclude: /node_modules/,
loader: 'babel'
}]
},
resolve: {
extensions: ['', '.js', '.jsx']
},
devServer: {
historyApiFallback: true,
contentBase: './'
}
};
我也試圖使用webpack捆綁我的應用程序,然後使用'firebase serve'運行它,任何提示? – astiefel