Total Complexity | 1 |
Complexity/F | 0 |
Lines of Code | 31 |
Function Count | 0 |
Duplicated Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | const nodeExternals = require('webpack-node-externals'); |
||
2 | const slsw = require('serverless-webpack'); |
||
3 | const path = require('path'); |
||
4 | |||
5 | module.exports = { |
||
6 | entry: slsw.lib.entries, |
||
7 | mode: slsw.lib.webpack.isLocal ? 'development' : 'production', |
||
8 | target: 'node', |
||
9 | externals: [nodeExternals()], |
||
10 | resolve: { |
||
11 | modules: [path.resolve('./src'), 'node_modules'], |
||
12 | }, |
||
13 | module: { |
||
14 | rules: [ |
||
15 | { |
||
16 | enforce: 'pre', |
||
17 | test: /\.js$/, |
||
18 | exclude: /node_modules/, |
||
19 | loader: 'eslint-loader', |
||
20 | options: { |
||
21 | fix: true, |
||
22 | }, |
||
23 | }, |
||
24 | { |
||
25 | test: /\.js$/, |
||
26 | exclude: /node_modules/, |
||
27 | use: 'babel-loader', |
||
28 | }, |
||
29 | ], |
||
30 | }, |
||
31 | }; |
||
32 |