]> git.r.bdr.sh - rbdr/serpentity/blob - config/webpack.cjs
Replace code and lab with ndoe test runner
[rbdr/serpentity] / config / webpack.cjs
1 const Path = require('path');
2
3 module.exports = {
4 entry: {
5 serpentity: './lib/serpentity.js',
6 'serpentity.min': './lib/serpentity.js'
7 },
8
9 output: {
10 path: Path.resolve(__dirname, '../dist'),
11 filename: '[name].js',
12 library: 'Serpentity',
13 libraryTarget: 'umd'
14 },
15
16 module: {
17 rules: [
18 {
19 test: /\.js$/,
20 exclude: /(node_modules|doc)/,
21 use: 'babel-loader'
22 }
23 ]
24 },
25
26 resolve: {
27 modules: [
28 'node_modules',
29 Path.resolve(__dirname, '../lib')
30 ],
31
32 extensions: ['.js']
33 },
34
35 context: Path.resolve(__dirname, '..'),
36
37 optimization: {
38 minimize: true
39 }
40 };