mirror of
https://github.com/Silverquark/dance.git
synced 2024-08-17 06:41:19 +03:00
52 lines
972 B
JavaScript
52 lines
972 B
JavaScript
const path = require("path");
|
|
const webpack = require("webpack");
|
|
|
|
module.exports = {
|
|
mode: "none",
|
|
target: "webworker",
|
|
entry: {
|
|
extension: "./src/extension.ts",
|
|
},
|
|
output: {
|
|
filename: "[name].js",
|
|
path: path.join(__dirname, "./out/web"),
|
|
libraryTarget: "commonjs",
|
|
},
|
|
resolve: {
|
|
mainFields: ["browser", "module", "main"],
|
|
extensions: [".ts", ".js"],
|
|
alias: {
|
|
child_process: false,
|
|
},
|
|
},
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.ts$/,
|
|
exclude: /node_modules/,
|
|
use: [
|
|
{
|
|
loader: "ts-loader",
|
|
},
|
|
],
|
|
},
|
|
],
|
|
},
|
|
plugins: [
|
|
new webpack.DefinePlugin({
|
|
"process.platform": '"web"',
|
|
"process.env.SHELL": "undefined",
|
|
}),
|
|
new webpack.ProvidePlugin({
|
|
process: "process/browser",
|
|
}),
|
|
],
|
|
externals: {
|
|
vscode: "commonjs vscode",
|
|
},
|
|
performance: {
|
|
hints: false,
|
|
},
|
|
devtool: "nosources-source-map",
|
|
};
|