mirror of
https://github.com/WeBankFinTech/fes.js.git
synced 2025-04-06 03:59:53 +08:00
fix: build 构建参数异常问题
This commit is contained in:
parent
bba04c7e5d
commit
cc8c392e62
8
packages/fes-template-h5/.fes.prod.js
Normal file
8
packages/fes-template-h5/.fes.prod.js
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
// .fes.js 只负责管理编译时配置,只能使用plain Object
|
||||||
|
|
||||||
|
|
||||||
|
export default {
|
||||||
|
request: {
|
||||||
|
base: '/api'
|
||||||
|
}
|
||||||
|
};
|
@ -4,6 +4,7 @@
|
|||||||
"description": "fes 移动端项目模版",
|
"description": "fes 移动端项目模版",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "fes build",
|
"build": "fes build",
|
||||||
|
"prod": "FES_ENV=prod fes build",
|
||||||
"dev": "fes dev"
|
"dev": "fes dev"
|
||||||
},
|
},
|
||||||
"keywords": [
|
"keywords": [
|
||||||
|
@ -29,7 +29,6 @@ const args = yParser(rawArgv);
|
|||||||
(async () => {
|
(async () => {
|
||||||
try {
|
try {
|
||||||
const command = args._[0];
|
const command = args._[0];
|
||||||
process.env.FES_ENV = args.mode || '';
|
|
||||||
if (command === 'dev') {
|
if (command === 'dev') {
|
||||||
const child = fork({
|
const child = fork({
|
||||||
scriptPath: require.resolve('./forkedDev')
|
scriptPath: require.resolve('./forkedDev')
|
||||||
|
@ -30,7 +30,6 @@ function onSignal(signal, service) {
|
|||||||
(async () => {
|
(async () => {
|
||||||
try {
|
try {
|
||||||
process.env.NODE_ENV = 'development';
|
process.env.NODE_ENV = 'development';
|
||||||
process.env.FES_ENV = args.mode || '';
|
|
||||||
const service = new Service({
|
const service = new Service({
|
||||||
cwd: getCwd(),
|
cwd: getCwd(),
|
||||||
pkg: getPkg(process.cwd()),
|
pkg: getPkg(process.cwd()),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user