@ray-js/build-plugin-router 0.20.0-beta.3 → 1.0.0

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.
Files changed (2) hide show
  1. package/lib/index.js +7 -0
  2. package/package.json +4 -4
package/lib/index.js CHANGED
@@ -241,7 +241,14 @@ function PluginRouter(api) {
241
241
  const subPkgs = (_d = subPackages !== null && subPackages !== void 0 ? subPackages : subpackages) !== null && _d !== void 0 ? _d : [];
242
242
  const pages = lodash_1.default.uniq(_routes.map((r) => r.path.replace(/^\//, '')));
243
243
  const tabBar = normalizeTabBarConfig(_tabBar, _routes, standardAppConfigFieldMap);
244
+ let workers = otherConfig.workers;
245
+ if (workers && typeof workers !== 'string') {
246
+ workers = workers.root;
247
+ }
244
248
  const config = Object.assign(Object.assign(Object.assign({}, g), otherConfig), { pages, tabBar });
249
+ if (workers) {
250
+ config.workers = workers;
251
+ }
245
252
  if (subPkgs && subPkgs.length) {
246
253
  config.subpackages = subPkgs.map((pkg) => {
247
254
  var _a;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ray-js/build-plugin-router",
3
- "version": "0.20.0-beta.3",
3
+ "version": "1.0.0",
4
4
  "description": "Ray build plugin for router",
5
5
  "keywords": [
6
6
  "ray"
@@ -21,7 +21,7 @@
21
21
  "watch": "tsc -p ./tsconfig.build.json --watch"
22
22
  },
23
23
  "dependencies": {
24
- "@ray-js/shared": "^0.20.0-beta.3",
24
+ "@ray-js/shared": "^1.0.0",
25
25
  "chokidar": "^3.5.2",
26
26
  "colors": "1.4.0",
27
27
  "ejs": "^3.1.6",
@@ -30,7 +30,7 @@
30
30
  "url": "^0.11.0"
31
31
  },
32
32
  "devDependencies": {
33
- "@ray-js/types": "^0.20.0-beta.3"
33
+ "@ray-js/types": "^1.0.0"
34
34
  },
35
35
  "maintainers": [
36
36
  {
@@ -38,6 +38,6 @@
38
38
  "email": "tuyafe@tuya.com"
39
39
  }
40
40
  ],
41
- "gitHead": "3d5fa0e2163d04add962ad52bd58dce3ed85081a",
41
+ "gitHead": "bcc9fee074c97125f75a48895d1a5e449a243eed",
42
42
  "repository": {}
43
43
  }