mirror of
https://github.com/elyby/accounts-frontend.git
synced 2024-11-30 02:32:58 +05:30
window.fetch polyfill
This commit is contained in:
parent
e2598883f7
commit
19eec8f7a4
@ -28,7 +28,8 @@
|
||||
"react-router": "^2.0.0-rc5",
|
||||
"react-router-redux": "^2.1.0",
|
||||
"redux": "^3.0.4",
|
||||
"redux-thunk": "^1.0.0"
|
||||
"redux-thunk": "^1.0.0",
|
||||
"whatwg-fetch": "^0.11.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"babel-core": "^6.0.0",
|
||||
@ -47,9 +48,10 @@
|
||||
"cssnano": "^3.4.0",
|
||||
"eslint": "^1.10.3",
|
||||
"eslint-plugin-react": "^3.13.1",
|
||||
"exports-loader": "^0.6.3",
|
||||
"extract-text-webpack-plugin": "^0.9.1",
|
||||
"html-webpack-plugin": "^1.7.0",
|
||||
"imports-loader": "^0.6.4",
|
||||
"imports-loader": "^0.6.5",
|
||||
"karma": "*",
|
||||
"karma-chai": "*",
|
||||
"karma-es5-shim": "*",
|
||||
|
@ -45,6 +45,7 @@ var webpackConfig = {
|
||||
app: path.join(__dirname, 'src'),
|
||||
vendor: [
|
||||
'babel-polyfill',
|
||||
'whatwg-fetch',
|
||||
'classnames',
|
||||
'history',
|
||||
'intl-format-cache',
|
||||
@ -111,6 +112,10 @@ var webpackConfig = {
|
||||
minify: {
|
||||
collapseWhitespace: isProduction
|
||||
}
|
||||
}),
|
||||
new webpack.ProvidePlugin({
|
||||
// window.fetch polyfill
|
||||
fetch: 'imports?this=>self!exports?self.fetch!whatwg-fetch'
|
||||
})
|
||||
].concat(isTest ? [] : [
|
||||
new webpack.optimize.CommonsChunkPlugin('vendor', 'vendor.js')
|
||||
|
Loading…
Reference in New Issue
Block a user