You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
const {
|
|
|
|
override,
|
|
|
|
addLessLoader,
|
|
|
|
disableEsLint,
|
|
|
|
addBundleVisualizer,
|
|
|
|
addWebpackAlias,
|
|
|
|
fixBabelImports,
|
|
|
|
addWebpackPlugin
|
|
|
|
} = require("customize-cra")
|
|
|
|
|
|
|
|
const path = require('path');
|
|
|
|
const MonacoWebpackPlugin = require('monaco-editor-webpack-plugin')
|
|
|
|
const ModuleScopePlugin = require('react-dev-utils/ModuleScopePlugin');
|
|
|
|
|
|
|
|
module.exports = override(
|
|
|
|
disableEsLint(),
|
|
|
|
// addBundleVisualizer(),
|
|
|
|
addLessLoader({
|
|
|
|
javascriptEnabled: true
|
|
|
|
}),
|
|
|
|
fixBabelImports('import', {
|
|
|
|
libraryName: 'antd',
|
|
|
|
libraryDirectory: 'es',
|
|
|
|
style: true
|
|
|
|
}),
|
|
|
|
addWebpackPlugin(new MonacoWebpackPlugin({})),
|
|
|
|
(config) => {
|
|
|
|
config.resolve.plugins = config.resolve.plugins.filter(plugin => !(plugin instanceof ModuleScopePlugin));
|
|
|
|
return config
|
|
|
|
},
|
|
|
|
addWebpackAlias({
|
|
|
|
"educoder": path.resolve(__dirname, './src/common/educoder.js')
|
|
|
|
})
|
|
|
|
);
|