@spcsn/taro-service 0.1.0 → 1.0.1
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/LICENSE +1 -153
- package/README.md +28 -0
- package/dist/index.d.ts +4 -5
- package/dist/index.js +6 -7
- package/dist/index.js.map +1 -1
- package/dist/platform-plugin-base/index.d.ts +0 -1
- package/dist/platform-plugin-base/index.js +0 -1
- package/dist/platform-plugin-base/index.js.map +1 -1
- package/dist/platform-plugin-base/mini.d.ts +10 -1
- package/dist/platform-plugin-base/mini.js +201 -43
- package/dist/platform-plugin-base/mini.js.map +1 -1
- package/dist/platform-plugin-base/platform.d.ts +1 -1
- package/dist/platform-plugin-base/platform.js +10 -14
- package/dist/platform-plugin-base/platform.js.map +1 -1
- package/dist/runner-utils/constant.d.ts +5 -0
- package/dist/runner-utils/constant.js +53 -0
- package/dist/runner-utils/constant.js.map +1 -0
- package/dist/runner-utils/index.d.ts +2 -0
- package/dist/runner-utils/index.js +19 -0
- package/dist/runner-utils/index.js.map +1 -0
- package/dist/runner-utils/vite.d.ts +10 -0
- package/dist/runner-utils/vite.js +10 -0
- package/dist/runner-utils/vite.js.map +1 -0
- package/dist/{Config.js → service-config.js} +27 -5
- package/dist/service-config.js.map +1 -0
- package/dist/{Kernel.d.ts → service-kernel.d.ts} +2 -2
- package/dist/{Kernel.js → service-kernel.js} +59 -17
- package/dist/service-kernel.js.map +1 -0
- package/dist/{Plugin.d.ts → service-plugin.d.ts} +1 -1
- package/dist/{Plugin.js → service-plugin.js} +5 -1
- package/dist/service-plugin.js.map +1 -0
- package/dist/utils/index.d.ts +2 -2
- package/dist/utils/index.js +28 -1
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/package.js +5 -4
- package/dist/utils/package.js.map +1 -1
- package/dist/utils/profile.d.ts +10 -0
- package/dist/utils/profile.js +51 -0
- package/dist/utils/profile.js.map +1 -0
- package/dist/utils/types.d.ts +3 -21
- package/package.json +15 -14
- package/dist/Config.js.map +0 -1
- package/dist/Kernel.js.map +0 -1
- package/dist/Plugin.js.map +0 -1
- package/dist/platform-plugin-base/web.d.ts +0 -32
- package/dist/platform-plugin-base/web.js +0 -150
- package/dist/platform-plugin-base/web.js.map +0 -1
- package/dist/platform-plugin-base/webpack/hmr-plugin.d.ts +0 -4
- package/dist/platform-plugin-base/webpack/hmr-plugin.js +0 -37
- package/dist/platform-plugin-base/webpack/hmr-plugin.js.map +0 -1
- /package/dist/{Config.d.ts → service-config.d.ts} +0 -0
package/LICENSE
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
3
|
Copyright (c) 2018 O2Team
|
|
4
|
+
Copyright (c) 2026 SPCSN contributors
|
|
4
5
|
|
|
5
6
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
7
|
of this software and associated documentation files (the "Software"), to deal
|
|
@@ -19,156 +20,3 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
|
19
20
|
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
21
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
22
|
SOFTWARE.
|
|
22
|
-
|
|
23
|
-
========================================================================
|
|
24
|
-
|
|
25
|
-
MIT (react-devtools):
|
|
26
|
-
The following files embed [react-devtools](https://github.com/facebook/react) MIT:
|
|
27
|
-
`/packages/taro-plugin-react-devtools/src/backend/index.js`
|
|
28
|
-
See `/LICENSE` for details of the license.
|
|
29
|
-
|
|
30
|
-
==================
|
|
31
|
-
|
|
32
|
-
MIT (vue-devtools):
|
|
33
|
-
The following files embed [vue-devtools](https://github.com/vuejs/devtools) MIT:
|
|
34
|
-
`/packages/taro-plugin-vue-devtools/src/backend/*`
|
|
35
|
-
See `/LICENSE` for details of the license.
|
|
36
|
-
|
|
37
|
-
==================
|
|
38
|
-
|
|
39
|
-
MIT (vite):
|
|
40
|
-
The following files embed [vite](https://github.com/vitejs/vite) MIT:
|
|
41
|
-
`/packages/taro-webpack5-prebundle/src/prebundle/scanImport.ts`,
|
|
42
|
-
`/packages/taro-webpack5-prebundle/src/prebundle/bundle.ts`,
|
|
43
|
-
`/packages/taro-webpack5-prebundle/src/h5.ts`,
|
|
44
|
-
`/packages/taro-webpack5-prebundle/src/min.ts`
|
|
45
|
-
See `/LICENSE` for details of the license.
|
|
46
|
-
|
|
47
|
-
==================
|
|
48
|
-
|
|
49
|
-
MIT (webpack):
|
|
50
|
-
The following files embed [webpack](https://github.com/webpack/webpack) MIT:
|
|
51
|
-
`/packages/taro-webpack5-prebundle/src/webpack/TaroContainerEntryModule.ts`,
|
|
52
|
-
`/packages/taro-webpack5-prebundle/src/webpack/TaroContainerPlugin.ts`,
|
|
53
|
-
`/packages/taro-webpack5-prebundle/src/webpack/TaroContainerReferencePlugin.ts`,
|
|
54
|
-
`/packages/taro-webpack5-prebundle/src/webpack/TaroModuleFederationPlugin.ts`
|
|
55
|
-
See `/LICENSE` for details of the license.
|
|
56
|
-
|
|
57
|
-
==================
|
|
58
|
-
|
|
59
|
-
MIT (sizzle):
|
|
60
|
-
The following files embed [sizzle](https://github.com/jquery/sizzle) MIT:
|
|
61
|
-
`/packages/taro-extends/src/jquery/sizzle.js`
|
|
62
|
-
See `/LICENSE.txt` for details of the license.
|
|
63
|
-
|
|
64
|
-
==================
|
|
65
|
-
|
|
66
|
-
MIT (zepto):
|
|
67
|
-
The following files embed [zepto](https://github.com/madrobby/zepto) MIT:
|
|
68
|
-
`/packages/taro-extends/src/jquery/zepto.js`,
|
|
69
|
-
`/packages/taro-extends/src/jquery/event.js`
|
|
70
|
-
See `/MIT-LICENSE` for details of the license.
|
|
71
|
-
|
|
72
|
-
==================
|
|
73
|
-
|
|
74
|
-
MIT (css-to-react-native):
|
|
75
|
-
The following files embed [css-to-react-native](https://github.com/styled-components/css-to-react-native) MIT:
|
|
76
|
-
`/packages/css-to-react-native/src/css-to-react-native/*`
|
|
77
|
-
See `/LICENSE.md` for details of the license.
|
|
78
|
-
|
|
79
|
-
==================
|
|
80
|
-
|
|
81
|
-
MIT (reactify-wc):
|
|
82
|
-
The following files embed [reactify-wc](https://github.com/BBKolton/reactify-wc) MIT:
|
|
83
|
-
`/packages/taro-components-library-react/src/component-lib/reactify-wc.ts`
|
|
84
|
-
See `/LICENSE` for details of the license.
|
|
85
|
-
|
|
86
|
-
==================
|
|
87
|
-
|
|
88
|
-
MIT (ant-design-mobile-rn):
|
|
89
|
-
The following files embed [ant-design-mobile-rn](https://github.com/ant-design/ant-design-mobile-rn) MIT:
|
|
90
|
-
`/packages/taro-components-rn/src/components/Swiper/carousel.tsx`
|
|
91
|
-
See `/LICENSE` for details of the license.
|
|
92
|
-
|
|
93
|
-
==================
|
|
94
|
-
|
|
95
|
-
MIT (react-wx-images-viewer):
|
|
96
|
-
The following files embed [react-wx-images-viewer](https://github.com/react-ld/react-wx-images-viewer) MIT:
|
|
97
|
-
`/packages/taro-h5/src/api/media/image/previewImage.ts`
|
|
98
|
-
See `/LICENSE` for details of the license.
|
|
99
|
-
|
|
100
|
-
==================
|
|
101
|
-
|
|
102
|
-
MIT (webpack-contrib/css-loader):
|
|
103
|
-
The following files embed [webpack-contrib/css-loader](https://github.com/webpack-contrib/css-loader) MIT:
|
|
104
|
-
`/packages/taro-rn-style-transformer/src/utils/index.ts`
|
|
105
|
-
See `/LICENSE` for details of the license.
|
|
106
|
-
|
|
107
|
-
==================
|
|
108
|
-
|
|
109
|
-
MIT (react-native):
|
|
110
|
-
The following files embed [react-native](https://github.com/facebook/react-native) MIT:
|
|
111
|
-
`/packages/taro-rn-style-transformer/src/transforms/StyleSheet/*`
|
|
112
|
-
See `/LICENSE` for details of the license.
|
|
113
|
-
|
|
114
|
-
==================
|
|
115
|
-
|
|
116
|
-
MIT (myrne/performance-now):
|
|
117
|
-
The following files embed [myrne/performance-now](https://github.com/myrne/performance-now) MIT:
|
|
118
|
-
`/packages/taro-runtime/src/bom/raf.ts`
|
|
119
|
-
See `/LICENSE` for details of the license.
|
|
120
|
-
|
|
121
|
-
==================
|
|
122
|
-
|
|
123
|
-
Apache (chameleon-api):
|
|
124
|
-
The following files embed [chameleon-api](https://github.com/chameleon-team/chameleon-api) Apache:
|
|
125
|
-
`/packages/taro-h5/src/api/device/clipboard.ts`
|
|
126
|
-
|
|
127
|
-
==================
|
|
128
|
-
|
|
129
|
-
MIT (uni-app):
|
|
130
|
-
The following files embed [uni-app](https://github.com/dcloudio/uni-app) MIT:
|
|
131
|
-
`/packages/taro-components-rn/src/components/Video/index.tsx`
|
|
132
|
-
See `/LICENSE` for details of the license.
|
|
133
|
-
|
|
134
|
-
==================
|
|
135
|
-
|
|
136
|
-
MIT (miniprogram-render):
|
|
137
|
-
The following files embed [miniprogram-render](https://github.com/Tencent/kbone) MIT:
|
|
138
|
-
`/packages/taro-plugin-http/src/runtime/Cookie.ts`
|
|
139
|
-
See `/LICENSE` for details of the license.
|
|
140
|
-
|
|
141
|
-
==================
|
|
142
|
-
|
|
143
|
-
MIT (stencil-ds-output-targets):
|
|
144
|
-
The following files embed [stencil-ds-output-targets](https://github.com/ionic-team/stencil-ds-output-targets/) MIT:
|
|
145
|
-
`/packages/taro-components-library-react/src/react-component-lib/utils/attachProps.ts`
|
|
146
|
-
`/packages/taro-components-library-react/src/react-component-lib/utils/case.ts`
|
|
147
|
-
`/packages/taro-components-library-react/src/react-component-lib/utils/dev.ts`
|
|
148
|
-
`/packages/taro-components-library-react/src/react-component-lib/utils/index.tsx`
|
|
149
|
-
`/packages/taro-components-library-react/src/react-component-lib/createComponent.tsx`
|
|
150
|
-
`/packages/taro-components-library-react/src/react-component-lib/createOverlayComponent.tsx`
|
|
151
|
-
`/packages/taro-components-library-react/src/react-component-lib/interfaces.ts`
|
|
152
|
-
`/packages/taro-components-library-vue3/src/vue-component-lib/utils.ts`
|
|
153
|
-
See `/LICENSE` for details of the license.
|
|
154
|
-
|
|
155
|
-
==================
|
|
156
|
-
|
|
157
|
-
MIT (weui):
|
|
158
|
-
The following files embed [weui](https://github.com/Tencent/weui) MIT:
|
|
159
|
-
`/packages/taro-components/src/components/*.scss`
|
|
160
|
-
See `/LICENSE.txt` for details of the license.
|
|
161
|
-
|
|
162
|
-
==================
|
|
163
|
-
|
|
164
|
-
Apache-2.0 (intersection-observer):
|
|
165
|
-
The following files embed [intersection-observer](https://github.com/GoogleChromeLabs/intersection-observer) Apache-2.0:
|
|
166
|
-
`/packages/taro-api/src/polyfill/intersection-observer.ts`
|
|
167
|
-
See `/LICENSE.txt` for details of the license.
|
|
168
|
-
|
|
169
|
-
==================
|
|
170
|
-
|
|
171
|
-
MIT (babel-plugin-jsx-dom-expressions):
|
|
172
|
-
The following files embed [babel-plugin-jsx-dom-expressions](https://github.com/ryansolid/dom-expressions/blob/main/packages/babel-plugin-jsx-dom-expressions) MIT:
|
|
173
|
-
`/packages/babel-plugin-transform-solid-jsx/src/*`
|
|
174
|
-
See `/LICENSE` for details of the license.
|
package/README.md
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# `@spcsn/taro-service`
|
|
2
|
+
|
|
3
|
+
`@spcsn/taro-service` 是 CLI 内部使用的插件化服务核心,基于 [tapable](https://github.com/webpack/tapable) 编排命令、生命周期钩子和构建插件。
|
|
4
|
+
|
|
5
|
+
## 包定位
|
|
6
|
+
|
|
7
|
+
- 内部实现包,不是业务侧显式安装入口。
|
|
8
|
+
- 由 `@spcsn/taro-cli` 直接使用,承载配置加载、插件注册、命令扩展和平台插件基础类。
|
|
9
|
+
- 当前仍需要独立发布,因为 CLI 入口和测试仍直接解析 `@spcsn/taro-service`。
|
|
10
|
+
|
|
11
|
+
## 主要功能
|
|
12
|
+
|
|
13
|
+
- 插件注册与加载。
|
|
14
|
+
- 生命周期钩子,例如 `onBuildStart`、`onBuildFinish`。
|
|
15
|
+
- 项目配置读取、校验与合并。
|
|
16
|
+
- 命令扩展,例如 `ctx.registerCommand`。
|
|
17
|
+
- 小程序平台插件基础能力。
|
|
18
|
+
|
|
19
|
+
## 依赖
|
|
20
|
+
|
|
21
|
+
- `@spcsn/taro-helper`: 编译时工具函数。
|
|
22
|
+
- `@spcsn/taro-shared`: 共享类型与常量。
|
|
23
|
+
- `tapable`: 钩子系统。
|
|
24
|
+
- `joi`: 配置校验。
|
|
25
|
+
|
|
26
|
+
## 收敛说明
|
|
27
|
+
|
|
28
|
+
后续如果要把本包并入 `@spcsn/taro-cli`,需要先调整 CLI 构建方式,把 service 代码和类型稳定打入 CLI 发布产物,再移除 CLI 对该包的 npm 级依赖。
|
package/dist/index.d.ts
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
import Config from './
|
|
2
|
-
import Kernel from './
|
|
3
|
-
import { TaroPlatform, TaroPlatformBase
|
|
1
|
+
import Config from './service-config';
|
|
2
|
+
import Kernel from './service-kernel';
|
|
3
|
+
import { TaroPlatform, TaroPlatformBase } from './platform-plugin-base';
|
|
4
4
|
export * from './utils/types';
|
|
5
|
-
export { Config, Kernel, TaroPlatform, TaroPlatformBase
|
|
5
|
+
export { Config, Kernel, TaroPlatform, TaroPlatformBase };
|
|
6
6
|
declare const _default: {
|
|
7
7
|
Config: typeof Config;
|
|
8
8
|
Kernel: typeof Kernel;
|
|
9
9
|
TaroPlatform: typeof TaroPlatform;
|
|
10
10
|
TaroPlatformBase: typeof TaroPlatformBase;
|
|
11
|
-
TaroPlatformWeb: typeof TaroPlatformWeb;
|
|
12
11
|
};
|
|
13
12
|
export default _default;
|
|
14
13
|
export type { IPluginContext } from './utils/types';
|
package/dist/index.js
CHANGED
|
@@ -17,15 +17,14 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
17
17
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
18
18
|
};
|
|
19
19
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
20
|
-
exports.
|
|
21
|
-
const
|
|
22
|
-
exports.Config =
|
|
23
|
-
const
|
|
24
|
-
exports.Kernel =
|
|
20
|
+
exports.TaroPlatformBase = exports.TaroPlatform = exports.Kernel = exports.Config = void 0;
|
|
21
|
+
const service_config_1 = __importDefault(require("./service-config"));
|
|
22
|
+
exports.Config = service_config_1.default;
|
|
23
|
+
const service_kernel_1 = __importDefault(require("./service-kernel"));
|
|
24
|
+
exports.Kernel = service_kernel_1.default;
|
|
25
25
|
const platform_plugin_base_1 = require("./platform-plugin-base");
|
|
26
26
|
Object.defineProperty(exports, "TaroPlatform", { enumerable: true, get: function () { return platform_plugin_base_1.TaroPlatform; } });
|
|
27
27
|
Object.defineProperty(exports, "TaroPlatformBase", { enumerable: true, get: function () { return platform_plugin_base_1.TaroPlatformBase; } });
|
|
28
|
-
Object.defineProperty(exports, "TaroPlatformWeb", { enumerable: true, get: function () { return platform_plugin_base_1.TaroPlatformWeb; } });
|
|
29
28
|
__exportStar(require("./utils/types"), exports);
|
|
30
|
-
exports.default = { Config:
|
|
29
|
+
exports.default = { Config: service_config_1.default, Kernel: service_kernel_1.default, TaroPlatform: platform_plugin_base_1.TaroPlatform, TaroPlatformBase: platform_plugin_base_1.TaroPlatformBase };
|
|
31
30
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,sEAAsC;AAK7B,iBALF,wBAAM,CAKE;AAJf,sEAAsC;AAIrB,iBAJV,wBAAM,CAIU;AAHvB,iEAAwE;AAG/C,6FAHhB,mCAAY,OAGgB;AAAE,iGAHhB,uCAAgB,OAGgB;AADvD,gDAA8B;AAE9B,kBAAe,EAAE,MAAM,EAAN,wBAAM,EAAE,MAAM,EAAN,wBAAM,EAAE,YAAY,EAAZ,mCAAY,EAAE,gBAAgB,EAAhB,uCAAgB,EAAE,CAAC"}
|
|
@@ -21,5 +21,4 @@ exports.TaroPlatform = void 0;
|
|
|
21
21
|
__exportStar(require("./mini"), exports);
|
|
22
22
|
var platform_1 = require("./platform");
|
|
23
23
|
Object.defineProperty(exports, "TaroPlatform", { enumerable: true, get: function () { return __importDefault(platform_1).default; } });
|
|
24
|
-
__exportStar(require("./web"), exports);
|
|
25
24
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/platform-plugin-base/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,uCAAqD;AAA5C,yHAAA,OAAO,OAAgB
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/platform-plugin-base/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA,yCAAuB;AACvB,uCAAqD;AAA5C,yHAAA,OAAO,OAAgB"}
|
|
@@ -23,7 +23,11 @@ export declare abstract class TaroPlatformBase<T extends TConfig = TConfig> exte
|
|
|
23
23
|
*/
|
|
24
24
|
private setup;
|
|
25
25
|
private setupImpl;
|
|
26
|
-
protected
|
|
26
|
+
protected printBuildSummary(): void;
|
|
27
|
+
private padEndByDisplayWidth;
|
|
28
|
+
private getTerminalDisplayWidth;
|
|
29
|
+
private isZeroWidthCodePoint;
|
|
30
|
+
private isFullWidthCodePoint;
|
|
27
31
|
/**
|
|
28
32
|
* 返回当前项目内的 runner 包
|
|
29
33
|
*/
|
|
@@ -38,6 +42,11 @@ export declare abstract class TaroPlatformBase<T extends TConfig = TConfig> exte
|
|
|
38
42
|
* @param extraOptions 需要额外传入 runner 的配置项
|
|
39
43
|
*/
|
|
40
44
|
private build;
|
|
45
|
+
private createBuildProgressController;
|
|
46
|
+
private printBuildResult;
|
|
47
|
+
private calculateDirectorySize;
|
|
48
|
+
private formatDuration;
|
|
49
|
+
private formatFileSize;
|
|
41
50
|
private buildImpl;
|
|
42
51
|
/**
|
|
43
52
|
* 生成 project.config.json
|
|
@@ -4,69 +4,113 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.TaroPlatformBase = void 0;
|
|
7
|
+
const node_fs_1 = require("node:fs");
|
|
8
|
+
const node_path_1 = require("node:path");
|
|
7
9
|
const taro_helper_1 = require("@spcsn/taro-helper");
|
|
8
10
|
const taro_shared_1 = require("@spcsn/taro-shared");
|
|
9
11
|
const package_1 = require("../utils/package");
|
|
12
|
+
const profile_js_1 = require("../utils/profile.js");
|
|
10
13
|
const platform_1 = __importDefault(require("./platform"));
|
|
11
14
|
class TaroPlatformBase extends platform_1.default {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
this.taroComponentsPath = taro_helper_1.taroJsMiniComponentsPath;
|
|
17
|
-
}
|
|
15
|
+
platformType = taro_shared_1.PLATFORM_TYPE.MINI;
|
|
16
|
+
// Note: 给所有的小程序平台一个默认的 taroComponentsPath
|
|
17
|
+
taroComponentsPath = taro_helper_1.taroJsMiniComponentsPath;
|
|
18
|
+
projectConfigJson;
|
|
18
19
|
/**
|
|
19
20
|
* 1. 清空 dist 文件夹
|
|
20
21
|
* 2. 输出编译提示
|
|
21
22
|
* 3. 生成 project.config.json
|
|
22
23
|
*/
|
|
23
24
|
async setup() {
|
|
24
|
-
await this.setupTransaction.perform(this.setupImpl, this);
|
|
25
|
+
await profile_js_1.serviceProfiler.measure('platform setup', () => this.setupTransaction.perform(this.setupImpl, this));
|
|
25
26
|
this.ctx.onSetupClose?.(this);
|
|
26
27
|
}
|
|
27
28
|
setupImpl() {
|
|
28
29
|
const { output } = this.config;
|
|
29
|
-
// webpack5 原生支持 output.clean 选项,但是 webpack4 不支持, 为统一行为,这里做一下兼容
|
|
30
|
-
// (在 packages/taro-mini-runner/src/webpack/chain.ts 和 packages/taro-webpack-runner/src/utils/chain.ts 的 makeConfig 中对 clean 选项做了过滤)
|
|
31
30
|
// 仅 output.clean 为 false 时不清空输出目录
|
|
32
|
-
|
|
33
|
-
|
|
31
|
+
if (output === undefined ||
|
|
32
|
+
output === null ||
|
|
33
|
+
output.clean === undefined ||
|
|
34
|
+
output.clean === null ||
|
|
35
|
+
output.clean === true) {
|
|
34
36
|
this.emptyOutputDir();
|
|
35
37
|
}
|
|
36
38
|
else if ((0, taro_shared_1.isObject)(output.clean)) {
|
|
37
39
|
this.emptyOutputDir(output.clean.keep || []);
|
|
38
40
|
}
|
|
39
|
-
this.
|
|
41
|
+
this.printBuildSummary();
|
|
40
42
|
if (this.projectConfigJson) {
|
|
41
43
|
this.generateProjectConfig(this.projectConfigJson);
|
|
42
44
|
}
|
|
43
|
-
if (this.ctx.initialConfig.logger?.quiet === false) {
|
|
44
|
-
const { printLog, processTypeEnum } = this.ctx.helper;
|
|
45
|
-
printLog("start" /* processTypeEnum.START */, '开发者工具-项目目录', `${this.ctx.paths.outputPath}`);
|
|
46
|
-
}
|
|
47
|
-
// Webpack5 已在 Vite-only fork 中移除,HMR 由 vite-runner 自身负责
|
|
48
45
|
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
46
|
+
printBuildSummary() {
|
|
47
|
+
if (process.env.NODE_ENV === 'test')
|
|
48
|
+
return;
|
|
52
49
|
const { chalk } = this.helper;
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
50
|
+
const isProduction = process.env.NODE_ENV === 'production';
|
|
51
|
+
const modeLabel = isProduction ? '生产模式' : '开发模式';
|
|
52
|
+
const modeHint = isProduction ? '准备端上桌,保持体面' : '小火预热,改完就尝';
|
|
53
|
+
const watchLabel = this.config.isWatch ? '守炉模式' : '单炉出餐';
|
|
54
|
+
const watchHint = this.config.isWatch ? '我看着烤箱,你放心加料' : '一炉定型,出炉就收工';
|
|
55
|
+
const minifyLabel = process.env.TARO_MINIFY === 'true' || isProduction ? '开启' : '关闭';
|
|
56
|
+
const humorLine = isProduction ? '小程序已出炉,适合端给用户。' : '烤箱常开,改完马上尝。';
|
|
57
|
+
const accent = chalk.hex('#ff4ecd');
|
|
58
|
+
const dimAccent = chalk.hex('#ff9af0');
|
|
59
|
+
const highlight = chalk.hex('#ff6fdd');
|
|
60
|
+
const contentWidth = 48;
|
|
61
|
+
const line = (content, color) => {
|
|
62
|
+
return accent('│') + color(this.padEndByDisplayWidth(content, contentWidth)) + accent('│');
|
|
63
|
+
};
|
|
64
|
+
const row = (label, value, hint, color) => {
|
|
65
|
+
const labelColumn = this.padEndByDisplayWidth(label, 4);
|
|
66
|
+
const valueColumn = this.padEndByDisplayWidth(value, 10);
|
|
67
|
+
return line(` ${labelColumn} ${valueColumn} ${hint}`, color);
|
|
68
|
+
};
|
|
69
|
+
const lines = [
|
|
70
|
+
accent(`╭${'─'.repeat(contentWidth)}╮`),
|
|
71
|
+
line(' SPCSN Taro 小程序烘焙坊已开张', highlight.bold),
|
|
72
|
+
line('', chalk.gray),
|
|
73
|
+
row('模式', modeLabel, modeHint, dimAccent),
|
|
74
|
+
row('目标', this.platform, 'React 19 小程序 × Skyline', highlight),
|
|
75
|
+
row('压缩', minifyLabel, '输出微信小程序产物', dimAccent),
|
|
76
|
+
row('节奏', watchLabel, watchHint, highlight),
|
|
77
|
+
line('', chalk.gray),
|
|
78
|
+
line(` ${humorLine}`, chalk.whiteBright),
|
|
79
|
+
accent(`╰${'─'.repeat(contentWidth)}╯`),
|
|
80
|
+
];
|
|
81
|
+
console.log(lines.join('\n'));
|
|
82
|
+
console.log();
|
|
83
|
+
}
|
|
84
|
+
padEndByDisplayWidth(content, targetWidth) {
|
|
85
|
+
const contentWidth = this.getTerminalDisplayWidth(content);
|
|
86
|
+
return content + ' '.repeat(Math.max(targetWidth - contentWidth, 0));
|
|
87
|
+
}
|
|
88
|
+
getTerminalDisplayWidth(content) {
|
|
89
|
+
return Array.from(content).reduce((width, character) => {
|
|
90
|
+
const codePoint = character.codePointAt(0);
|
|
91
|
+
if (!codePoint || this.isZeroWidthCodePoint(codePoint))
|
|
92
|
+
return width;
|
|
93
|
+
return width + (this.isFullWidthCodePoint(codePoint) ? 2 : 1);
|
|
94
|
+
}, 0);
|
|
95
|
+
}
|
|
96
|
+
isZeroWidthCodePoint(codePoint) {
|
|
97
|
+
return (codePoint === 0x200d ||
|
|
98
|
+
(codePoint >= 0x0300 && codePoint <= 0x036f) ||
|
|
99
|
+
(codePoint >= 0xfe00 && codePoint <= 0xfe0f));
|
|
100
|
+
}
|
|
101
|
+
isFullWidthCodePoint(codePoint) {
|
|
102
|
+
return (codePoint >= 0x1100 &&
|
|
103
|
+
(codePoint <= 0x115f ||
|
|
104
|
+
codePoint === 0x2329 ||
|
|
105
|
+
codePoint === 0x232a ||
|
|
106
|
+
(codePoint >= 0x2e80 && codePoint <= 0xa4cf && codePoint !== 0x303f) ||
|
|
107
|
+
(codePoint >= 0xac00 && codePoint <= 0xd7a3) ||
|
|
108
|
+
(codePoint >= 0xf900 && codePoint <= 0xfaff) ||
|
|
109
|
+
(codePoint >= 0xfe10 && codePoint <= 0xfe19) ||
|
|
110
|
+
(codePoint >= 0xfe30 && codePoint <= 0xfe6f) ||
|
|
111
|
+
(codePoint >= 0xff00 && codePoint <= 0xff60) ||
|
|
112
|
+
(codePoint >= 0xffe0 && codePoint <= 0xffe6) ||
|
|
113
|
+
(codePoint >= 0x1f300 && codePoint <= 0x1faff)));
|
|
70
114
|
}
|
|
71
115
|
/**
|
|
72
116
|
* 返回当前项目内的 runner 包
|
|
@@ -74,8 +118,8 @@ ${exampleCommand}`));
|
|
|
74
118
|
async getRunner() {
|
|
75
119
|
const { appPath } = this.ctx.paths;
|
|
76
120
|
const { npm } = this.helper;
|
|
77
|
-
const runnerPkg = '@spcsn/taro-
|
|
78
|
-
const runner = await npm.getNpmPkg(runnerPkg, appPath);
|
|
121
|
+
const runnerPkg = '@spcsn/taro-mini-runner';
|
|
122
|
+
const runner = await profile_js_1.serviceProfiler.measure('load runner module', () => npm.getNpmPkg(runnerPkg, appPath));
|
|
79
123
|
return runner.bind(null, appPath);
|
|
80
124
|
}
|
|
81
125
|
/**
|
|
@@ -108,17 +152,131 @@ ${exampleCommand}`));
|
|
|
108
152
|
* @param extraOptions 需要额外传入 runner 的配置项
|
|
109
153
|
*/
|
|
110
154
|
async build(extraOptions = {}) {
|
|
155
|
+
if (this.config.withoutBuild)
|
|
156
|
+
return;
|
|
111
157
|
this.ctx.onBuildInit?.(this);
|
|
112
|
-
|
|
158
|
+
const buildStartMs = Date.now();
|
|
159
|
+
const progress = this.createBuildProgressController();
|
|
160
|
+
progress.start();
|
|
161
|
+
try {
|
|
162
|
+
await this.buildTransaction.perform(this.buildImpl, this, extraOptions);
|
|
163
|
+
progress.finish();
|
|
164
|
+
if (!this.config.isWatch) {
|
|
165
|
+
this.printBuildResult(Date.now() - buildStartMs);
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
catch (error) {
|
|
169
|
+
progress.fail();
|
|
170
|
+
throw error;
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
createBuildProgressController() {
|
|
174
|
+
const noop = () => { };
|
|
175
|
+
if (process.env.NODE_ENV === 'test' || process.env.CI || this.config.isWatch || !process.stdout.isTTY) {
|
|
176
|
+
return {
|
|
177
|
+
start: noop,
|
|
178
|
+
finish: noop,
|
|
179
|
+
fail: noop,
|
|
180
|
+
};
|
|
181
|
+
}
|
|
182
|
+
const { chalk } = this.helper;
|
|
183
|
+
const barLength = 18;
|
|
184
|
+
const frames = [18, 42, 66, 88];
|
|
185
|
+
const accent = chalk.hex('#ff4ecd');
|
|
186
|
+
const dimAccent = chalk.hex('#4a163f');
|
|
187
|
+
const glow = chalk.hex('#ff9af0');
|
|
188
|
+
let currentFrameIndex = 0;
|
|
189
|
+
let timer;
|
|
190
|
+
const render = (percent, label) => {
|
|
191
|
+
const filledLength = Math.round((percent / 100) * barLength);
|
|
192
|
+
const bar = Array.from({ length: barLength }, (_, index) => {
|
|
193
|
+
if (index === filledLength - 1 && percent < 100)
|
|
194
|
+
return glow('◆');
|
|
195
|
+
return index < filledLength ? accent('━') : dimAccent('·');
|
|
196
|
+
}).join('');
|
|
197
|
+
const percentLabel = `${percent}%`.padStart(4, ' ');
|
|
198
|
+
process.stdout.write(`\r\u001B[2K${accent('出炉进度')} ${glow(percentLabel)} ${accent('⟦')}${bar}${accent('⟧')} ${label}`);
|
|
199
|
+
};
|
|
200
|
+
const clearLine = () => {
|
|
201
|
+
process.stdout.write('\n');
|
|
202
|
+
};
|
|
203
|
+
return {
|
|
204
|
+
start() {
|
|
205
|
+
render(8, '开炉预热');
|
|
206
|
+
timer = setInterval(() => {
|
|
207
|
+
const percent = frames[Math.min(currentFrameIndex, frames.length - 1)];
|
|
208
|
+
currentFrameIndex += 1;
|
|
209
|
+
render(percent, '代码正在换上小程序外套');
|
|
210
|
+
}, 180);
|
|
211
|
+
},
|
|
212
|
+
finish() {
|
|
213
|
+
if (timer)
|
|
214
|
+
clearInterval(timer);
|
|
215
|
+
render(100, '小程序出炉,收工');
|
|
216
|
+
clearLine();
|
|
217
|
+
},
|
|
218
|
+
fail() {
|
|
219
|
+
if (timer)
|
|
220
|
+
clearInterval(timer);
|
|
221
|
+
render(100, chalk.red('烘焙翻车'));
|
|
222
|
+
clearLine();
|
|
223
|
+
},
|
|
224
|
+
};
|
|
225
|
+
}
|
|
226
|
+
printBuildResult(durationMs) {
|
|
227
|
+
if (process.env.NODE_ENV === 'test')
|
|
228
|
+
return;
|
|
229
|
+
const { chalk } = this.helper;
|
|
230
|
+
const outputSize = this.calculateDirectorySize(this.ctx.paths.outputPath);
|
|
231
|
+
const durationLabel = this.formatDuration(durationMs);
|
|
232
|
+
const outputSizeLabel = this.formatFileSize(outputSize);
|
|
233
|
+
console.log(chalk.greenBright(`✨ 小程序出炉:耗时 ${durationLabel} · 产物总体积 ${outputSizeLabel}`));
|
|
234
|
+
console.log();
|
|
235
|
+
}
|
|
236
|
+
calculateDirectorySize(directoryPath) {
|
|
237
|
+
if (!(0, node_fs_1.existsSync)(directoryPath))
|
|
238
|
+
return 0;
|
|
239
|
+
return (0, node_fs_1.readdirSync)(directoryPath, { withFileTypes: true }).reduce((totalSize, entry) => {
|
|
240
|
+
const entryPath = (0, node_path_1.join)(directoryPath, entry.name);
|
|
241
|
+
if (entry.isDirectory())
|
|
242
|
+
return totalSize + this.calculateDirectorySize(entryPath);
|
|
243
|
+
if (entry.isFile())
|
|
244
|
+
return totalSize + (0, node_fs_1.statSync)(entryPath).size;
|
|
245
|
+
return totalSize;
|
|
246
|
+
}, 0);
|
|
247
|
+
}
|
|
248
|
+
formatDuration(durationMs) {
|
|
249
|
+
if (durationMs < 1000)
|
|
250
|
+
return `${durationMs}ms`;
|
|
251
|
+
const durationSeconds = durationMs / 1000;
|
|
252
|
+
if (durationSeconds < 60)
|
|
253
|
+
return `${durationSeconds.toFixed(2)}s`;
|
|
254
|
+
const minutes = Math.floor(durationSeconds / 60);
|
|
255
|
+
const seconds = durationSeconds % 60;
|
|
256
|
+
return `${minutes}m ${seconds.toFixed(2)}s`;
|
|
257
|
+
}
|
|
258
|
+
formatFileSize(sizeInBytes) {
|
|
259
|
+
if (sizeInBytes < 1024)
|
|
260
|
+
return `${sizeInBytes} B`;
|
|
261
|
+
const units = ['KB', 'MB', 'GB'];
|
|
262
|
+
let size = sizeInBytes / 1024;
|
|
263
|
+
let unitIndex = 0;
|
|
264
|
+
while (size >= 1024 && unitIndex < units.length - 1) {
|
|
265
|
+
size /= 1024;
|
|
266
|
+
unitIndex += 1;
|
|
267
|
+
}
|
|
268
|
+
return `${size.toFixed(2)} ${units[unitIndex]}`;
|
|
113
269
|
}
|
|
114
270
|
async buildImpl(extraOptions = {}) {
|
|
115
|
-
const runner = await this.getRunner();
|
|
271
|
+
const runner = await profile_js_1.serviceProfiler.measure('prepare runner', () => this.getRunner());
|
|
272
|
+
const getOptionsStartMs = profile_js_1.serviceProfiler.start();
|
|
116
273
|
const options = this.getOptions(Object.assign({
|
|
117
274
|
runtimePath: this.runtimePath,
|
|
118
275
|
taroComponentsPath: this.taroComponentsPath,
|
|
119
276
|
behaviorsName: this.behaviorsName,
|
|
120
277
|
}, extraOptions));
|
|
121
|
-
|
|
278
|
+
profile_js_1.serviceProfiler.end('prepare runner options', getOptionsStartMs);
|
|
279
|
+
await profile_js_1.serviceProfiler.measure('run runner', () => runner(options));
|
|
122
280
|
}
|
|
123
281
|
/**
|
|
124
282
|
* 生成 project.config.json
|
|
@@ -158,7 +316,7 @@ ${exampleCommand}`));
|
|
|
158
316
|
*/
|
|
159
317
|
async start() {
|
|
160
318
|
await this.setup();
|
|
161
|
-
await this.build();
|
|
319
|
+
await profile_js_1.serviceProfiler.measure('platform build', () => this.build());
|
|
162
320
|
}
|
|
163
321
|
}
|
|
164
322
|
exports.TaroPlatformBase = TaroPlatformBase;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mini.js","sourceRoot":"","sources":["../../src/platform-plugin-base/mini.ts"],"names":[],"mappings":";;;;;;AAAA,oDAA8E;AAC9E,oDAA6D;AAE7D,8CAAiD;AACjD,0DAAsC;AAatC,MAAsB,gBAA8C,SAAQ,kBAAe;IAA3F;;QACE,iBAAY,GAAG,2BAAa,CAAC,IAAI,CAAC;QAKlC,0CAA0C;QAC1C,uBAAkB,GAAW,sCAAwB,CAAC;IAyKxD,CAAC;IAtKC;;;;OAIG;IACK,KAAK,CAAC,KAAK;QACjB,MAAM,IAAI,CAAC,gBAAgB,CAAC,OAAO,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,CAAC;QAC1D,IAAI,CAAC,G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,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC;gBAC5D,CAAC;gBACD,OAAO,GAAG,CAAC,GAAG,CAAC,CAAC;YAClB,CAAC;iBAAM,IAAI,MAAM,CAAC,GAAG,CAAC,KAAK,KAAK,EAAE,CAAC;gBACjC,OAAO,GAAG,CAAC,GAAG,CAAC,CAAC;YAClB,CAAC;iBAAM,IAAI,OAAO,GAAG,CAAC,GAAG,CAAC,KAAK,QAAQ,EAAE,CAAC;gBACxC,IAAI,CAAC,0BAA0B,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,MAAM,CAAC,CAAC;YACpD,CAAC;QACH,CAAC,CAAC,CAAC;IACL,CAAC;IAED;;OAEG;IACI,KAAK,CAAC,KAAK;QAChB,MAAM,IAAI,CAAC,KAAK,EAAE,CAAC;QACnB,MAAM,4BAAe,CAAC,OAAO,CAAC,gBAAgB,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC;IACtE,CAAC;CACF;AA1VD,4CA0VC"}
|
|
@@ -27,7 +27,7 @@ export default abstract class TaroPlatform<T extends TConfig = TConfig> {
|
|
|
27
27
|
getConfig(): T;
|
|
28
28
|
protected emptyOutputDir(excludes?: Array<string | RegExp>): void;
|
|
29
29
|
/**
|
|
30
|
-
*
|
|
30
|
+
* 如果分端编译详情配置了 output.path,则需更新 outputPath 位置
|
|
31
31
|
*/
|
|
32
32
|
private updateOutputPath;
|
|
33
33
|
/**
|