Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module.exports = {
- build: {
- extend (config, { isServer }) {
- if (isServer) {
- config.externals = [
- nodeExternals({
- whitelist: [/zomp-ui/, /vue-js-toggle-button/]
- })
- ]
- }
- // console.log(config.externals)
- const babelLoader = config.module.rules.find((rule) => rule.loader === 'babel-loader')
- babelLoader.exclude = function(modulePath) {
- return /node_modules/.test(modulePath) && !/zomp-ui/.test(modulePath);
- }
- }
- }
- }
Add Comment
Please, Sign In to add comment