lowcode-engine/packages/demo/build.plugin.js
kangwei 5767023d3f Revert "Merge branch 'feat/rax-simulator' into 'release/0.9.0' "
This reverts commit 44d0f0b246c6b92af9c8c5d4d019286568d434ad, reversing
changes made to d282a375425435e7e292ab0f819141b6e50f541d.
2020-07-20 14:01:00 +08:00

24 lines
658 B
JavaScript

const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
const MonacoWebpackPlugin = require('monaco-editor-webpack-plugin');
module.exports = ({ onGetWebpackConfig }) => {
onGetWebpackConfig((config) => {
config.resolve.plugin('tsconfigpaths').use(TsconfigPathsPlugin, [
{
configFile: './tsconfig.json',
},
]);
config
// 定义插件名称
.plugin('MonacoWebpackPlugin')
// 第一项为具体插件,第二项为插件参数
.use(new MonacoWebpackPlugin({
languages:["typescript","css","json"]
}), []);
config.plugins.delete('hot');
config.devServer.hot(false);
});
};