Some checks failed
Build Docker Image for Pull Request / build (pull_request) Failing after 35s
33 lines
692 B
JavaScript
33 lines
692 B
JavaScript
const path = require('path');
|
|
const { EnvironmentPlugin } = require('webpack');
|
|
|
|
module.exports = (env) => {
|
|
const url = env.URL || 'http://localhost';
|
|
|
|
return {
|
|
entry: '../background.js',
|
|
target: 'web',
|
|
mode: 'production',
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.js?$/,
|
|
use: 'babel-loader',
|
|
exclude: /node_modules/,
|
|
},
|
|
],
|
|
},
|
|
resolve: { extensions: ['.tsx', '.ts', '.js'] },
|
|
output: {
|
|
filename: 'background.bundle.js',
|
|
path: path.resolve(__dirname, '../'),
|
|
publicPath: '',
|
|
},
|
|
plugins: [
|
|
new EnvironmentPlugin({
|
|
WEBRTC_INTERNALS_EXPORTER_URL: url,
|
|
}),
|
|
],
|
|
};
|
|
};
|