Passed
Push — master ( 6b1336...6f64d3 )
by Jean
01:57
created

webpack.config.js (7 issues)

1
const path = require('path');
2
const webpack = require('webpack');
0 ignored issues
show
The constant webpack seems to be never used. Consider removing it.
Loading history...
'webpack' is assigned a value but never used.
Loading history...
3
const pkg = require('./package.json');
0 ignored issues
show
The constant pkg seems to be never used. Consider removing it.
Loading history...
'pkg' is assigned a value but never used.
Loading history...
4
const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
0 ignored issues
show
The constant UglifyJsPlugin seems to be never used. Consider removing it.
Loading history...
'UglifyJsPlugin' is assigned a value but never used.
Loading history...
5
6
module.exports = {
7
    entry: './src/index.js',
8
    mode: 'production', // 'development' https://webpack.js.org/configuration/mode/
9
10
    output: {
11
        path: path.join(__dirname, 'build'),
12
        filename: 'jquery.nouislider-range-input.js',
13
        libraryTarget: 'umd',
14
    },
15
16
    module: {
17
        rules: [
18
            {
19
                test: /\.js$/,
20
                exclude: /node_modules/,
21
                loader: 'babel-loader',
22
            },
23
        ],
24
    },
25
26
    plugins: [
27
        // new webpack.BannerPlugin({
28
        // banner: `${pkg.name}\n${pkg.version}\nTested with jQuery 1.12+\n${pkg.repository.url}\nLicense: ${pkg.license}`,
0 ignored issues
show
This line exceeds the maximum configured line length of 100.
Loading history...
29
        // }),
30
        // new UglifyJsPlugin({
31
        // beautify: true,
32
        // mangle: false,
33
        // }),
34
    ],
35
36
    externals: {
37
        jquery: {
38
            commonjs: 'jquery',
39
            commonjs2: 'jquery',
40
            amd: 'jquery',
41
            root: 'jQuery',
42
        },
43
        nouislider: 'nouislider',
44
        wnumb: 'wnumb',
45
    },
46
};
47