mirror of
https://github.com/lensapp/lens.git
synced 2024-11-10 18:55:52 +03:00
91bef77997
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
66 lines
1.3 KiB
JavaScript
66 lines
1.3 KiB
JavaScript
const path = require('path');
|
|
|
|
module.exports = [
|
|
{
|
|
entry: './main.ts',
|
|
context: __dirname,
|
|
target: "electron-main",
|
|
mode: "production",
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.tsx?$/,
|
|
use: 'ts-loader',
|
|
exclude: /node_modules/,
|
|
},
|
|
],
|
|
},
|
|
externals: [
|
|
{
|
|
"@k8slens/extensions": "var global.LensExtensions",
|
|
"mobx": "var global.Mobx",
|
|
"react": "var global.React"
|
|
}
|
|
],
|
|
resolve: {
|
|
extensions: [ '.tsx', '.ts', '.js' ],
|
|
},
|
|
output: {
|
|
libraryTarget: "commonjs2",
|
|
filename: 'main.js',
|
|
path: path.resolve(__dirname, 'dist'),
|
|
},
|
|
},
|
|
{
|
|
entry: './renderer.tsx',
|
|
context: __dirname,
|
|
target: "electron-renderer",
|
|
mode: "production",
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.tsx?$/,
|
|
use: 'ts-loader',
|
|
exclude: /node_modules/,
|
|
},
|
|
],
|
|
},
|
|
externals: [
|
|
{
|
|
"@k8slens/extensions": "var global.LensExtensions",
|
|
"react": "var global.React",
|
|
"mobx": "var global.Mobx"
|
|
}
|
|
],
|
|
resolve: {
|
|
extensions: [ '.tsx', '.ts', '.js' ],
|
|
},
|
|
output: {
|
|
libraryTarget: "commonjs2",
|
|
globalObject: "this",
|
|
filename: 'renderer.js',
|
|
path: path.resolve(__dirname, 'dist'),
|
|
},
|
|
},
|
|
];
|