hblang-vscode/webpack.config.js

34 lines
583 B
JavaScript
Raw Normal View History

2024-09-28 09:34:34 -05:00
const path = require('path');
module.exports = {
mode: 'production',
entry: './src/main.ts',
output: {
path: path.resolve(__dirname, 'out'),
filename: 'main.js',
2024-11-15 15:20:50 -06:00
libraryTarget: 'commonjs2'
2024-09-28 09:34:34 -05:00
},
resolve: {
extensions: ['.ts', '.js'],
fallback: {
2024-11-15 15:20:50 -06:00
"child_process": false,
"fs": false,
"os": require.resolve("os-browserify/browser"),
"path": require.resolve("path-browserify"),
2024-09-28 09:34:34 -05:00
},
},
externals: {
2024-11-15 15:20:50 -06:00
vscode: 'commonjs vscode'
2024-09-28 09:34:34 -05:00
},
module: {
rules: [
{
test: /\.ts$/,
use: 'ts-loader',
exclude: /node_modules/
}
]
},
2024-11-15 15:20:50 -06:00
target: 'node'
2024-09-28 09:34:34 -05:00
};