GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

webpack.blender.js   A
last analyzed

Complexity

Total Complexity 2
Complexity/F 0

Size

Lines of Code 71
Function Count 0

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
wmc 2
eloc 49
mnd 2
bc 2
fnc 0
dl 0
loc 71
rs 10
bpm 0
cpm 0
noi 0
c 0
b 0
f 0
1
/**
2
 * This file is part of the O2System Framework package.
3
 *
4
 * For the full copyright and license information, please view the LICENSE
5
 * file that was distributed with this source code.
6
 *
7
 * @author         Steeve Andrian Salim
8
 * @copyright      Copyright (c) Steeve Andrian Salim
9
 */
10
// ------------------------------------------------------------------------
11
12
let blender = require('o2system-blender');
13
const HtmlWebpackPlugin = require('html-webpack-plugin');
14
15
const path = require('path');
16
const isDev = process.env.NODE_ENV !== 'production';
17
18
blender.setOutputPath('assets/');
19
blender.setResourceRoot('');
20
21
let htmlFilename = 'index';
22
if(typeof process.env.npm_config_filename !== 'undefined') {
23
    htmlFilename = process.env.npm_config_filename;
24
}
25
26
if(isDev) {
27
    blender.setPublicPath('./docs/');
28
29
    blender.webpackConfig({
30
        output: {
31
            path: path.resolve(__dirname, './docs/'),
32
            publicPath: './'
33
        },
34
        devServer: {
35
            contentBase: './docs/',
36
            hot: true,
37
            open: true,
38
        },
39
        devtool: 'source-map',
40
        mode: 'development',
41
        module: {
42
            rules: [
43
                {
44
                    test: /\.(html)$/,
45
                    include: path.join(__dirname, 'src/partials'),
46
                    use: {
47
                        loader: 'html-loader',
48
                        options: {
49
                          minimize: false,
50
                          interpolate: true
51
                        }
52
                    }
53
                }
54
            ]
55
        },
56
        plugins: [
57
            new HtmlWebpackPlugin({
58
                title: 'O2System Venus Form UI',
59
                template: './src/' + htmlFilename + '.html',
60
                inject: 'body',
61
                filename: htmlFilename + '.html',
62
                hash: true
63
            })
64
        ]
65
    });
66
    
67
    blender.js('./src/Form.js', './docs/venus-form-ui.js')
68
        .sass('./src/Form.scss', './docs/venus-form-ui.css')
69
} else {
70
    blender.setPublicPath('./dist/');
71
72
    blender.webpackConfig({
73
        output: {
74
            path: path.resolve(__dirname, './dist/'),
75
            publicPath: './'
76
        },
77
        mode: 'production'
78
    });
79
    
80
    blender.js('./src/Form.js', './dist/venus-form-ui.js')
81
        .sass('./src/Form.scss', './dist/venus-form-ui.css');
82
}