@hlw-uni/mp-cli 1.0.19 → 1.0.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/cli.js CHANGED
File without changes
package/package.json CHANGED
@@ -1,38 +1,38 @@
1
1
  {
2
- "name": "@hlw-uni/mp-cli",
3
- "version": "1.0.19",
4
- "description": "uniapp 小程序脚手架生成器",
5
- "main": "bin/cli.js",
6
- "bin": {
7
- "hlw-uni-mp": "./bin/cli.js"
8
- },
9
- "keywords": [
10
- "uniapp",
11
- "scaffold",
12
- "weixin",
13
- "toutiao",
14
- "miniprogram"
15
- ],
16
- "author": "hlw2326",
17
- "license": "MIT",
18
- "dependencies": {
19
- "chalk": "^4.1.2",
20
- "commander": "^11.1.0",
21
- "fs-extra": "^11.2.0",
22
- "inquirer": "^8.2.7",
23
- "ora": "^5.4.1"
24
- },
25
- "devDependencies": {
26
- "@types/fs-extra": "^11.0.4",
27
- "@types/node": "^20.11.0",
28
- "esbuild": "^0.28.0",
29
- "tsx": "^4.19.0"
30
- },
31
- "scripts": {
32
- "dev": "tsx bin/cli.ts",
33
- "create": "tsx bin/cli.ts create",
34
- "build": "esbuild bin/cli.ts --bundle --platform=node --outfile=bin/cli.js --format=cjs --external:fs-extra --external:inquirer --external:chalk --external:commander --external:ora --external:path --external:fs",
35
- "prepublish": "pnpm build",
36
- "postbuild": "node scripts/fix-templates-path.js"
37
- }
38
- }
2
+ "name": "@hlw-uni/mp-cli",
3
+ "version": "1.0.20",
4
+ "description": "uniapp 小程序脚手架生成器",
5
+ "main": "bin/cli.js",
6
+ "bin": {
7
+ "hlw-uni-mp": "./bin/cli.js"
8
+ },
9
+ "scripts": {
10
+ "dev": "tsx bin/cli.ts",
11
+ "create": "tsx bin/cli.ts create",
12
+ "build": "esbuild bin/cli.ts --bundle --platform=node --outfile=bin/cli.js --format=cjs --external:fs-extra --external:inquirer --external:chalk --external:commander --external:ora --external:path --external:fs",
13
+ "prepublish": "pnpm build",
14
+ "postbuild": "node scripts/fix-templates-path.js"
15
+ },
16
+ "keywords": [
17
+ "uniapp",
18
+ "scaffold",
19
+ "weixin",
20
+ "toutiao",
21
+ "miniprogram"
22
+ ],
23
+ "author": "hlw2326",
24
+ "license": "MIT",
25
+ "dependencies": {
26
+ "chalk": "^4.1.2",
27
+ "commander": "^11.1.0",
28
+ "fs-extra": "^11.2.0",
29
+ "inquirer": "^8.2.7",
30
+ "ora": "^5.4.1"
31
+ },
32
+ "devDependencies": {
33
+ "@types/fs-extra": "^11.0.4",
34
+ "@types/node": "^20.11.0",
35
+ "esbuild": "^0.28.0",
36
+ "tsx": "^4.19.0"
37
+ }
38
+ }
@@ -11,7 +11,7 @@
11
11
  "@dcloudio/uni-app-plus": "3.0.0-4080420251103001",
12
12
  "@dcloudio/uni-components": "3.0.0-4080420251103001",
13
13
  "@dcloudio/uni-mp-toutiao": "3.0.0-4080420251103001",
14
- "@hlw-uni/mp-core": "^1.0.7",
14
+ "@hlw-uni/mp-core": "^1.0.9",
15
15
  "@hlw-uni/mp-vue": "^1.0.2",
16
16
  "@vueuse/core": "^10.9.0",
17
17
  "pinia": "^2.1.7",
@@ -22,7 +22,7 @@
22
22
  "@dcloudio/types": "^3.4.8",
23
23
  "@dcloudio/uni-cli-shared": "3.0.0-4080420251103001",
24
24
  "@dcloudio/vite-plugin-uni": "3.0.0-4080420251103001",
25
- "@hlw-uni/mp-vite-plugin": "^1.0.8",
25
+ "@hlw-uni/mp-vite-plugin": "^1.0.9",
26
26
  "@unocss/transformer-directives": "^66.1.1",
27
27
  "@vue/tsconfig": "^0.1.3",
28
28
  "sass": "^1.70.0",
@@ -7,6 +7,7 @@ import { useUserStore } from "./stores/user";
7
7
 
8
8
  // 注册默认拦截器(Token + 业务错误 + 401)
9
9
  setupDefaultInterceptors({
10
+ baseURL: (import.meta.env as Record<string, string>).VITE_API_BASE_URL ?? "",
10
11
  getToken: () => useUserStore().token,
11
12
  onUnauthorized: () => {
12
13
  useUserStore().$patch({ token: "", userInfo: null });
@@ -12,7 +12,7 @@
12
12
  "@dcloudio/uni-app-plus": "3.0.0-4080420251103001",
13
13
  "@dcloudio/uni-components": "3.0.0-4080420251103001",
14
14
  "@dcloudio/uni-mp-weixin": "3.0.0-4080420251103001",
15
- "@hlw-uni/mp-core": "^1.0.8",
15
+ "@hlw-uni/mp-core": "^1.0.9",
16
16
  "@hlw-uni/mp-vue": "^1.0.2",
17
17
  "@vueuse/core": "^10.9.0",
18
18
  "pinia": "^2.1.7",
@@ -23,7 +23,7 @@
23
23
  "@dcloudio/types": "^3.4.8",
24
24
  "@dcloudio/uni-cli-shared": "3.0.0-4080420251103001",
25
25
  "@dcloudio/vite-plugin-uni": "3.0.0-4080420251103001",
26
- "@hlw-uni/mp-vite-plugin": "^1.0.8",
26
+ "@hlw-uni/mp-vite-plugin": "^1.0.9",
27
27
  "@unocss/transformer-directives": "^66.1.1",
28
28
  "@vue/tsconfig": "^0.1.3",
29
29
  "sass": "^1.70.0",
@@ -7,6 +7,7 @@ import { useUserStore } from "./stores/user";
7
7
 
8
8
  // 注册默认拦截器(Token + 业务错误 + 401)
9
9
  setupDefaultInterceptors({
10
+ baseURL: (import.meta.env as Record<string, string>).VITE_API_BASE_URL ?? "",
10
11
  getToken: () => useUserStore().token,
11
12
  onUnauthorized: () => {
12
13
  useUserStore().$patch({ token: "", userInfo: null });
@@ -1,5 +1,5 @@
1
1
  {
2
- "name": "",
2
+ "name": "hlw-uni",
3
3
  "appid": "",
4
4
  "description": "",
5
5
  "versionName": "1.0.0",
@@ -7,7 +7,11 @@
7
7
  "transformPx": false,
8
8
  "mp-weixin": {
9
9
  "appid": "",
10
- "setting": { "urlCheck": false },
10
+ "setting": {
11
+ "urlCheck": false,
12
+ "postcss": true,
13
+ "minified": true
14
+ },
11
15
  "usingComponents": true
12
16
  }
13
17
  }