mirror of
https://github.com/kou029w/_.git
synced 2025-01-31 06:18:07 +00:00
25 lines
568 B
JavaScript
25 lines
568 B
JavaScript
|
const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin')
|
||
|
const nodeExternals = require('webpack-node-externals')
|
||
|
const NodemonPlugin = require('nodemon-webpack-plugin')
|
||
|
|
||
|
module.exports = {
|
||
|
entry: './index.ts',
|
||
|
target: 'node',
|
||
|
node: {
|
||
|
__dirname: false
|
||
|
},
|
||
|
output: {
|
||
|
filename: 'index.js',
|
||
|
path: __dirname
|
||
|
},
|
||
|
module: {
|
||
|
rules: [{ test: /\.ts$/, loader: 'ts-loader' }]
|
||
|
},
|
||
|
plugins: [new NodemonPlugin()],
|
||
|
resolve: {
|
||
|
extensions: ['.ts', '.js'],
|
||
|
plugins: [new TsconfigPathsPlugin()]
|
||
|
},
|
||
|
externals: [nodeExternals()]
|
||
|
}
|