Sha256: fb027e27c900c1c295f4d45a6a51dc17a6cca47e174b03bc7760ab171abc9431

Contents?: true

Size: 1.12 KB

Versions: 12

Compression:

Stored size: 1.12 KB

Contents

'use strict';

const TerserPlugin = require('terser-webpack-plugin');
const webpack = require('webpack');

function criWrapper(_, options, callback) {
    window.criRequest(options, callback); // eslint-disable-line no-undef
}

module.exports = {
    mode: 'production',
    resolve: {
        fallback: {
            'util': require.resolve('util/'),
            'url': require.resolve('url/'),
            'http': false,
            'https': false,
            'dns': false
        },
        alias: {
            'ws': './websocket-wrapper.js'
        }
    },
    externals: [
        {
            './external-request.js': `var (${criWrapper})`
        }
    ],
    plugins: [
        new webpack.ProvidePlugin({
            process: 'process/browser',
        }),
    ],
    optimization: {
        minimizer: [
            new TerserPlugin({
                extractComments: false,
            })
        ],
    },
    entry: ['babel-polyfill', './index.js'],
    output: {
        path: __dirname,
        filename: 'chrome-remote-interface.js',
        libraryTarget: process.env.TARGET || 'commonjs2',
        library: 'CDP'
    }
};

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
opal-1.8.3.rc1 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.8.2 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.8.1 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.8.0 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.8.0.beta1 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.7.4 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.8.0.alpha1 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.7.3 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.7.2 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.7.1 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.7.0 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js
opal-1.7.0.rc1 lib/opal/cli_runners/node_modules/chrome-remote-interface/webpack.config.js