mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2025-12-12 19:52:51 +00:00
17 lines
460 B
JavaScript
17 lines
460 B
JavaScript
const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
|
|
|
|
module.exports = ({ context, onGetWebpackConfig }) => {
|
|
onGetWebpackConfig((config) => {
|
|
config.resolve.plugin('tsconfigpaths').use(TsconfigPathsPlugin, [
|
|
{
|
|
configFile: './tsconfig.json',
|
|
},
|
|
]);
|
|
config.plugins.delete('hot');
|
|
config.devServer.hot(false);
|
|
if (context.command === 'start') {
|
|
config.devtool('inline-source-map');
|
|
}
|
|
});
|
|
};
|