tabby-osc-notify/webpack.config.js

40 lines
814 B
JavaScript

const path = require("path");
module.exports = {
target: "node",
entry: "src/index.ts",
devtool: "source-map",
context: __dirname,
mode: "development",
output: {
path: path.resolve(__dirname, "dist"),
filename: "index.js",
pathinfo: true,
libraryTarget: "umd"
},
resolve: {
modules: [".", "src", "node_modules"].map(x => path.join(__dirname, x)),
extensions: [ ".js", ".ts" ]
},
module: {
rules: [
{
test: /\.ts$/,
loader: "ts-loader",
options: {
configFile: path.resolve(__dirname, "tsconfig.json")
}
},
{
test: /\.scss/,
use: [ "style-loader", "css-loader", "sass-lodaer" ]
},
{
test: /\.pug$/,
use: [ "apply-loader", "pug-loader" ]
}
]
},
externals: [ "fs", "ngx-toastr", /^rxjs/, /^@angular/, /^@ng-bootstrap/, /^tabby-/ ]
};