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.
37 lines
862 B
37 lines
862 B
/* eslint-disable @typescript-eslint/no-var-requires */
|
|
const path = require('path');
|
|
const {
|
|
override,
|
|
addWebpackModuleRule,
|
|
addWebpackPlugin,
|
|
addWebpackAlias,
|
|
} = require('customize-cra');
|
|
const ArcoWebpackPlugin = require('@arco-plugins/webpack-react');
|
|
const addLessLoader = require('customize-cra-less-loader');
|
|
const setting = require('./src/settings.json');
|
|
|
|
module.exports = {
|
|
webpack: override(
|
|
addLessLoader({
|
|
lessLoaderOptions: {
|
|
lessOptions: {},
|
|
},
|
|
}),
|
|
addWebpackModuleRule({
|
|
test: /\.svg$/,
|
|
loader: '@svgr/webpack',
|
|
}),
|
|
addWebpackPlugin(
|
|
new ArcoWebpackPlugin({
|
|
theme: '@arco-themes/react-arco-pro',
|
|
modifyVars: {
|
|
'arcoblue-6': setting.themeColor,
|
|
},
|
|
})
|
|
),
|
|
addWebpackAlias({
|
|
'@': path.resolve(__dirname, 'src'),
|
|
})
|
|
),
|
|
};
|