123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354 |
- const { IgnorePlugin } = require('webpack');
- const CopyWebpackPlugin = require('copy-webpack-plugin');
- const path = require('path');
- module.exports = {
- entry: './src/app.ts',
- // devtool: 'inline-source-map',
- module: {
- rules: [
- {
- test: /\.tsx?$/,
- use: 'ts-loader',
- exclude: /node_modules/,
- },
- ],
- },
- resolve: {
- extensions: ['.js', '.tsx', '.ts' ],
- alias: {
- "@src": path.resolve(__dirname, "src"),
- "@root": path.resolve(__dirname, "../"),
- "@classes": path.resolve(__dirname, "../base-lib/src/classes/"),
- "@core": path.resolve(__dirname, "../base-lib/src/core/"),
- "@util": path.resolve(__dirname, "../base-lib/src/util/"),
- "@core-models": path.resolve(__dirname, "../base-lib/src/core-models/"),
- "@core-guards": path.resolve(__dirname, "../base-lib/src/core-guards/")
- },
- fallback: {
- "_stream_transform": false
- }
- },
- target: 'node',
- externals:{
- "fs": "commonjs fs",
- "net": "commonjs net"
- },
- plugins: [
- new IgnorePlugin({
- resourceRegExp: /^pg-native$/,
- }),
- new CopyWebpackPlugin({
- patterns: [
- {from: 'config.json'},
- ]
- })
- ],
- output: {
- filename: 'index.js',
- path: path.resolve(__dirname, '../__dist/pmr-biz-manager'),
- },
- optimization: {
- minimize: false
- }
- };
|