@ray-js/builder-mp 1.2.20 → 1.2.22
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/lib/build.js +2 -6
- package/lib/build.rjs.js +4 -1
- package/lib/build.worker.js +4 -1
- package/package.json +5 -5
package/lib/build.js
CHANGED
@@ -59,13 +59,9 @@ function build(options, context) {
|
|
59
59
|
const rayCoreOpts = (0, ray_core_1.getRayCoreOptions)();
|
60
60
|
const rayApi = new ray_core_1.RayAPI(rayCoreOpts);
|
61
61
|
const compiler = (0, legacyExport_1.buildMini)(rayApi, rayCoreOpts);
|
62
|
-
|
63
|
-
workerBuild.run();
|
62
|
+
new build_worker_1.default(compileOptions, compiler);
|
64
63
|
if (target === 'thing') {
|
65
|
-
|
66
|
-
compiler.hooks.afterCompile.tap(LOG_PREFIX, () => {
|
67
|
-
rjsBuild.run();
|
68
|
-
});
|
64
|
+
new build_rjs_1.default(compileOptions, compiler);
|
69
65
|
}
|
70
66
|
return compiler;
|
71
67
|
});
|
package/lib/build.rjs.js
CHANGED
@@ -21,6 +21,7 @@ class RjsBuild {
|
|
21
21
|
this.options = options;
|
22
22
|
this.parent = parent;
|
23
23
|
this.initRjsBuilder();
|
24
|
+
this.run();
|
24
25
|
}
|
25
26
|
createWebpackConfig() {
|
26
27
|
const { cwd, output, mini, target } = this.options;
|
@@ -147,7 +148,9 @@ class RjsBuild {
|
|
147
148
|
}
|
148
149
|
}
|
149
150
|
else {
|
150
|
-
this.
|
151
|
+
this.parent.hooks.afterCompile.tap(LOG_PREFIX_RJS, () => {
|
152
|
+
this.compiler.run(cb);
|
153
|
+
});
|
151
154
|
}
|
152
155
|
return this.compiler;
|
153
156
|
}
|
package/lib/build.worker.js
CHANGED
@@ -21,6 +21,7 @@ class WorkerBuild {
|
|
21
21
|
this.options = options;
|
22
22
|
this.parent = parent;
|
23
23
|
this.initWorkerBuilder();
|
24
|
+
this.run();
|
24
25
|
}
|
25
26
|
createWebpackConfig() {
|
26
27
|
const { cwd, output, mini, target } = this.options;
|
@@ -166,7 +167,9 @@ class WorkerBuild {
|
|
166
167
|
});
|
167
168
|
}
|
168
169
|
else {
|
169
|
-
this.
|
170
|
+
this.parent.hooks.afterCompile.tap(LOG_PREFIX_WORKER, () => {
|
171
|
+
this.compiler.run(cb);
|
172
|
+
});
|
170
173
|
}
|
171
174
|
return this.compiler;
|
172
175
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ray-js/builder-mp",
|
3
|
-
"version": "1.2.
|
3
|
+
"version": "1.2.22",
|
4
4
|
"description": "Ray builder for mini program",
|
5
5
|
"keywords": [
|
6
6
|
"ray"
|
@@ -30,10 +30,10 @@
|
|
30
30
|
"@ray-core/build-store": "0.2.10",
|
31
31
|
"@ray-core/cli": "0.2.10",
|
32
32
|
"@ray-core/ray": "0.2.10",
|
33
|
-
"@ray-js/adapter": "^1.2.
|
33
|
+
"@ray-js/adapter": "^1.2.22",
|
34
34
|
"@ray-js/rjs-for-wechat": "^0.0.3",
|
35
|
-
"@ray-js/shared": "^1.2.
|
36
|
-
"@ray-js/types": "^1.2.
|
35
|
+
"@ray-js/shared": "^1.2.22",
|
36
|
+
"@ray-js/types": "^1.2.22",
|
37
37
|
"babel-loader": "^8.2.3",
|
38
38
|
"babel-plugin-minify-dead-code-elimination": "^0.5.1",
|
39
39
|
"babel-plugin-transform-prune-unused-imports": "^1.0.1",
|
@@ -64,6 +64,6 @@
|
|
64
64
|
"email": "tuyafe@tuya.com"
|
65
65
|
}
|
66
66
|
],
|
67
|
-
"gitHead": "
|
67
|
+
"gitHead": "a0fd2d86aaa677aa0b93188cbccda069dfee8de8",
|
68
68
|
"repository": {}
|
69
69
|
}
|