修改项目 build 结构

This commit is contained in:
张成
2026-02-08 12:14:10 +08:00
parent e07f2ad2d1
commit 1d0d2edaa2
11 changed files with 193 additions and 146 deletions

2
types/global.d.ts vendored
View File

@@ -17,6 +17,8 @@ declare namespace NodeJS {
NODE_ENV: 'development' | 'production',
/** 当前构建的平台 */
TARO_ENV: 'weapp' | 'swan' | 'alipay' | 'h5' | 'rn' | 'tt' | 'quickapp' | 'qq' | 'jd'
/** 应用环境标识 */
APP_ENV: 'dev' | 'dev_local' | 'sit' | 'pr'
/**
* 当前构建的小程序 appid
* @description 若不同环境有不同的小程序,可通过在 env 文件中配置环境变量`TARO_APP_ID`来方便快速切换 appid 而不必手动去修改 dist/project.config.json 文件