1 | const { BannerPlugin } = require('webpack');
|
2 | const merge = require('deepmerge');
|
3 |
|
4 | module.exports = (neutrino, options = {}) => {
|
5 | neutrino.config
|
6 | .plugin(options.pluginId || 'banner')
|
7 | .use(BannerPlugin, [
|
8 | merge({
|
9 | banner: 'require(\'source-map-support\').install();',
|
10 | test: neutrino.regexFromExtensions(),
|
11 | raw: true,
|
12 | entryOnly: true
|
13 | }, options)
|
14 | ]);
|
15 | };
|