Configuration

Create-react-app can be configured in "/config-overrides.js" by react-app-rewired extension.

Create-React-App docs: https://facebook.github.io/create-react-app/docs/getting-started

Config overrides: https://github.com/timarney/react-app-rewired and https://github.com/arackaf/customize-cra

config-overrides.js
// Overriding CreateReactApp settings, ref: https://github.com/arackaf/customize-cra
const antdTheme = require('./src/theme.js')
const {
override,
fixBabelImports,
addLessLoader,
useEslintRc,
addDecoratorsLegacy,
} = require('customize-cra')
module.exports = override(
addDecoratorsLegacy(),
useEslintRc(),
fixBabelImports('import', {
libraryName: 'antd', libraryDirectory: 'es', style: true
}),
addLessLoader({
javascriptEnabled: true,
modifyVars: antdTheme
})
)