1 Star 2 Fork 2

胡乱想的你猜/vue2基础模板

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
vue.config.js 1.16 KB
一键复制 编辑 原始数据 按行查看 历史
胡乱想的你猜 提交于 2023-10-02 17:28 . 添加看板娘
'use strict'
const path = require('path')
const defaultSettings = require('./src/settings.js')
function resolve(dir) {
return path.join(__dirname, dir)
}
const name = defaultSettings.title || 'XSSQ' // page title
const port = process.env.port || process.env.npm_config_port || 9528 // dev port
// All configuration item explanations can be find in https://cli.vuejs.org/config/
module.exports = {
publicPath: './',
outputDir: 'dist',
assetsDir: 'static',
lintOnSave: process.env.NODE_ENV === 'development',
productionSourceMap: false,
devServer: {
disableHostCheck: true,
port: port,
open: true,
hot: true,
overlay: {
warnings: false,
errors: true
},
proxy: {
// key: value 的形式指定需要转发的路径: 转发的目标
'/api': {
target: 'http://xnj-win:9000',
changeOrigin: true
}
}
// before: require('./mock/mock-server.js')
},
configureWebpack: {
// provide the app's title in webpack's name field, so that
// it can be accessed in index.html to inject the correct title.
name: name,
resolve: {
alias: {
'@': resolve('src')
}
}
}
}
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/su402315731/vue2-basic-template.git
git@gitee.com:su402315731/vue2-basic-template.git
su402315731
vue2-basic-template
vue2基础模板
master

搜索帮助