@modern-js/plugin-ssg 2.22.1 → 2.23.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/CHANGELOG.md CHANGED
@@ -1,5 +1,32 @@
1
1
  # @modern-js/plugin-ssg
2
2
 
3
+ ## 2.23.1
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies [f08bbfc]
8
+ - Updated dependencies [a6b313a]
9
+ - Updated dependencies [8f2cab0]
10
+ - @modern-js/utils@2.23.1
11
+
12
+ ## 2.23.0
13
+
14
+ ### Patch Changes
15
+
16
+ - 7e6fb5f: chore: publishConfig add provenance config
17
+
18
+ chore: publishConfig 增加 provenance 配置
19
+
20
+ - c3216b5: chore: split the scheme into the plugin
21
+
22
+ chore: 拆分 scheme 到插件内部
23
+
24
+ - Updated dependencies [7e6fb5f]
25
+ - Updated dependencies [a7a7ad7]
26
+ - Updated dependencies [6dec7c2]
27
+ - Updated dependencies [c3216b5]
28
+ - @modern-js/utils@2.23.0
29
+
3
30
  ## 2.22.1
4
31
 
5
32
  ### Patch Changes
package/dist/cjs/index.js CHANGED
@@ -27,7 +27,24 @@ const _default = () => ({
27
27
  const agreedRouteMap = {};
28
28
  return {
29
29
  validateSchema() {
30
- return _utils.PLUGIN_SCHEMAS["@modern-js/plugin-ssg"];
30
+ return [
31
+ {
32
+ target: "output.ssg",
33
+ schema: {
34
+ oneOf: [
35
+ {
36
+ type: "boolean"
37
+ },
38
+ {
39
+ type: "object"
40
+ },
41
+ {
42
+ instanceof: "Function"
43
+ }
44
+ ]
45
+ }
46
+ }
47
+ ];
31
48
  },
32
49
  modifyFileSystemRoutes({ entrypoint, routes }) {
33
50
  const { entryName } = entrypoint;
package/dist/esm/index.js CHANGED
@@ -3,7 +3,7 @@ import { _ as _object_spread } from "@swc/helpers/_/_object_spread";
3
3
  import { _ as _object_spread_props } from "@swc/helpers/_/_object_spread_props";
4
4
  import { _ as _ts_generator } from "@swc/helpers/_/_ts_generator";
5
5
  import path from "path";
6
- import { logger, PLUGIN_SCHEMAS } from "@modern-js/utils";
6
+ import { logger } from "@modern-js/utils";
7
7
  import { generatePath } from "react-router-dom";
8
8
  import { flattenRoutes, formatOutput, isDynamicUrl, readJSONSpec, standardOptions, writeJSONSpec } from "./libs/util";
9
9
  import { createServer } from "./server";
@@ -21,7 +21,24 @@ export default function() {
21
21
  var agreedRouteMap = {};
22
22
  return {
23
23
  validateSchema: function validateSchema() {
24
- return PLUGIN_SCHEMAS["@modern-js/plugin-ssg"];
24
+ return [
25
+ {
26
+ target: "output.ssg",
27
+ schema: {
28
+ oneOf: [
29
+ {
30
+ type: "boolean"
31
+ },
32
+ {
33
+ type: "object"
34
+ },
35
+ {
36
+ instanceof: "Function"
37
+ }
38
+ ]
39
+ }
40
+ }
41
+ ];
25
42
  },
26
43
  modifyFileSystemRoutes: function modifyFileSystemRoutes(param) {
27
44
  var entrypoint = param.entrypoint, routes = param.routes;
@@ -1,5 +1,5 @@
1
1
  import path from "path";
2
- import { logger, PLUGIN_SCHEMAS } from "@modern-js/utils";
2
+ import { logger } from "@modern-js/utils";
3
3
  import { generatePath } from "react-router-dom";
4
4
  import { flattenRoutes, formatOutput, isDynamicUrl, readJSONSpec, standardOptions, writeJSONSpec } from "./libs/util";
5
5
  import { createServer } from "./server";
@@ -16,7 +16,24 @@ export default () => ({
16
16
  const agreedRouteMap = {};
17
17
  return {
18
18
  validateSchema() {
19
- return PLUGIN_SCHEMAS["@modern-js/plugin-ssg"];
19
+ return [
20
+ {
21
+ target: "output.ssg",
22
+ schema: {
23
+ oneOf: [
24
+ {
25
+ type: "boolean"
26
+ },
27
+ {
28
+ type: "object"
29
+ },
30
+ {
31
+ instanceof: "Function"
32
+ }
33
+ ]
34
+ }
35
+ }
36
+ ];
20
37
  },
21
38
  modifyFileSystemRoutes({ entrypoint, routes }) {
22
39
  const { entryName } = entrypoint;
package/package.json CHANGED
@@ -15,7 +15,7 @@
15
15
  "modern",
16
16
  "modern.js"
17
17
  ],
18
- "version": "2.22.1",
18
+ "version": "2.23.1",
19
19
  "jsnext:source": "./src/index.ts",
20
20
  "types": "./dist/types/index.d.ts",
21
21
  "main": "./dist/cjs/index.js",
@@ -63,7 +63,7 @@
63
63
  "normalize-path": "^3.0.0",
64
64
  "portfinder": "^1.0.28",
65
65
  "@swc/helpers": "0.5.1",
66
- "@modern-js/utils": "2.22.1"
66
+ "@modern-js/utils": "2.23.1"
67
67
  },
68
68
  "peerDependencies": {
69
69
  "react-router-dom": ">=5.1.2"
@@ -81,16 +81,17 @@
81
81
  "react-dom": "^18",
82
82
  "react-router-dom": "^6.8.1",
83
83
  "typescript": "^5",
84
- "@modern-js/app-tools": "2.22.1",
85
- "@modern-js/prod-server": "2.22.1",
86
- "@modern-js/types": "2.22.1",
87
- "@scripts/build": "2.22.1",
88
- "@scripts/jest-config": "2.22.1"
84
+ "@modern-js/types": "2.23.1",
85
+ "@modern-js/app-tools": "2.23.1",
86
+ "@modern-js/prod-server": "2.23.1",
87
+ "@scripts/build": "2.23.1",
88
+ "@scripts/jest-config": "2.23.1"
89
89
  },
90
90
  "sideEffects": false,
91
91
  "publishConfig": {
92
92
  "registry": "https://registry.npmjs.org/",
93
- "access": "public"
93
+ "access": "public",
94
+ "provenance": true
94
95
  },
95
96
  "scripts": {
96
97
  "new": "modern-lib new",