Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.use('eslint-loader')
.loader(require.resolve('eslint-loader'))
.options(eslintOptions);
});
}
function getId(id) {
return `alita:${id}`;
}
function noop() {
return true;
}
const reactPlugin = require('umi-plugin-react').default;
reactPlugin(api, opts.umi);
const registerConfigArr = ['retainLog', 'appType', 'umi', 'tongjiCode', 'gaCode', 'mainPath', 'complexRoute', 'keepalive'];
registerConfigArr.forEach(item => {
api._registerConfig(() => {
return () => {
return {
name: item,
validate: noop,
onChange(newConfig) {
api.restart(`${item} change`);
},
};
};
});
})