mon-entreprise/source/webpack.prod.legacyBrowser.js

28 lines
610 B
JavaScript
Raw Normal View History

const { map } = require('ramda')
const prod = require('./webpack.prod.js')
2019-07-08 09:13:51 +00:00
const {
commonLoaders,
styleLoader,
HTMLPlugins
} = require('./webpack.common.js')
const { EnvironmentPlugin } = require('webpack')
module.exports = {
...prod,
entry: map(entry => ['whatwg-fetch', entry], prod.entry),
output: {
filename: '[name].legacy.bundle.js'
},
module: {
rules: [...commonLoaders({ legacy: true }), styleLoader('style-loader')]
},
plugins: [
2019-07-08 09:13:51 +00:00
...HTMLPlugins({ injectTrackingScript: true }),
new EnvironmentPlugin({
EN_SITE: '/infrance${path}',
FR_SITE: '/mon-entreprise${path}'
})
]
}