代码拉取完成,页面将自动刷新
同步操作将从 刘亚平/简搭云在线可视化表单设计,低码平台 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
const path = require('path')
const resolve = (dir) => {
return path.join(__dirname, dir)
}
const shell = require('shelljs')
const prod = process.env.npm_lifecycle_event
shell.cp(`./src/configs/${prod}.js`, './src/configs/index.js')
module.exports = {
publicPath: './',
lintOnSave: false,
chainWebpack: (config) => {
const svgRule = config.module.rule('svg')
svgRule.exclude.add(resolve('src/icons')).end()
config.module
.rule('icons')
.test(/\.svg$/)
.include.add(resolve('src/icons'))
.end()
.use('svg-sprite-loader')
.loader('svg-sprite-loader')
.options({
symbolId: 'icon-[name]',
})
.end()
config.plugin('define').tap((args) => {
// .env
args[0]['process.env'].BASE_URL = JSON.stringify(process.env.BASE_URL)
return args
})
},
configureWebpack: () => {
const myConfig = {}
myConfig.plugins = []
myConfig.devServer = {
disableHostCheck: true, // 禁用webpack热重载检查 解决热更新失效问题
host: 'localhost',
port: 8083,
https: false,
proxy: {
'/jd': {
// 要请求的后台地址113.240.220.22\http://localhost:8181/net3vs
target: 'http://localhost:8089/iagrain/a/',
ws: true, // 启用websockets
changeOrigin: true, // 是否跨域
pathRewrite: {
'^/jd': '', // 这里理解成用路径中的‘/dev/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替
},
},
},
}
myConfig.devtool = 'source-map'
return myConfig
},
runtimeCompiler: true,
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。