@modern-js/plugin-ssg 1.0.0-rc.4 → 1.0.0-rc.9

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,65 @@
1
1
  # @modern-js/plugin-ssg
2
2
 
3
+ ## 1.0.0-rc.9
4
+
5
+ ### Patch Changes
6
+
7
+ - 224f7fe: fix server route match
8
+ - 204c626: feat: initial
9
+ - Updated dependencies [224f7fe]
10
+ - Updated dependencies [204c626]
11
+ - @modern-js/core@1.0.0-rc.9
12
+ - @modern-js/babel-chain@1.0.0-rc.9
13
+ - @modern-js/utils@1.0.0-rc.9
14
+
15
+ ## 1.0.0-rc.8
16
+
17
+ ### Patch Changes
18
+
19
+ - 224f7fe: fix server route match
20
+ - 204c626: feat: initial
21
+ - Updated dependencies [224f7fe]
22
+ - Updated dependencies [204c626]
23
+ - @modern-js/core@1.0.0-rc.8
24
+ - @modern-js/babel-chain@1.0.0-rc.8
25
+ - @modern-js/utils@1.0.0-rc.8
26
+
27
+ ## 1.0.0-rc.7
28
+
29
+ ### Patch Changes
30
+
31
+ - 224f7fe: fix server route match
32
+ - 204c626: feat: initial
33
+ - Updated dependencies [224f7fe]
34
+ - Updated dependencies [204c626]
35
+ - @modern-js/core@1.0.0-rc.7
36
+ - @modern-js/babel-chain@1.0.0-rc.7
37
+ - @modern-js/utils@1.0.0-rc.7
38
+
39
+ ## 1.0.0-rc.6
40
+
41
+ ### Patch Changes
42
+
43
+ - 224f7fe: fix server route match
44
+ - 204c626: feat: initial
45
+ - Updated dependencies [224f7fe]
46
+ - Updated dependencies [204c626]
47
+ - @modern-js/core@1.0.0-rc.6
48
+ - @modern-js/babel-chain@1.0.0-rc.6
49
+ - @modern-js/utils@1.0.0-rc.6
50
+
51
+ ## 1.0.0-rc.5
52
+
53
+ ### Patch Changes
54
+
55
+ - 224f7fe: fix server route match
56
+ - 204c626: feat: initial
57
+ - Updated dependencies [224f7fe]
58
+ - Updated dependencies [204c626]
59
+ - @modern-js/core@1.0.0-rc.5
60
+ - @modern-js/babel-chain@1.0.0-rc.5
61
+ - @modern-js/utils@1.0.0-rc.5
62
+
3
63
  ## 1.0.0-rc.4
4
64
 
5
65
  ### Patch Changes
@@ -54,13 +54,9 @@ export default createPlugin(() => {
54
54
  // eslint-disable-next-line max-statements
55
55
  async afterBuild() {
56
56
  // eslint-disable-next-line react-hooks/rules-of-hooks
57
- const {
58
- value: resolvedConfig
59
- } = useResolvedConfigContext(); // eslint-disable-next-line react-hooks/rules-of-hooks
57
+ const resolvedConfig = useResolvedConfigContext(); // eslint-disable-next-line react-hooks/rules-of-hooks
60
58
 
61
- const {
62
- value: appContext
63
- } = useAppContext();
59
+ const appContext = useAppContext();
64
60
  const {
65
61
  appDirectory
66
62
  } = appContext;
@@ -21,9 +21,7 @@ export const createServer = (ssgRoutes, apiRoutes, options, appDirectory) => new
21
21
  cwd: appDirectory,
22
22
  silent: true
23
23
  });
24
- const {
25
- value: appContext
26
- } = useAppContext();
24
+ const appContext = useAppContext();
27
25
  const serverPlugins = appContext.plugins.filter(p => p.server).map(p => p.server);
28
26
  const plugins = serverPlugins.map(p => p.name);
29
27
  cp.send(JSON.stringify({
@@ -72,13 +72,9 @@ var _default = (0, _core.createPlugin)(() => {
72
72
  // eslint-disable-next-line max-statements
73
73
  async afterBuild() {
74
74
  // eslint-disable-next-line react-hooks/rules-of-hooks
75
- const {
76
- value: resolvedConfig
77
- } = (0, _core.useResolvedConfigContext)(); // eslint-disable-next-line react-hooks/rules-of-hooks
75
+ const resolvedConfig = (0, _core.useResolvedConfigContext)(); // eslint-disable-next-line react-hooks/rules-of-hooks
78
76
 
79
- const {
80
- value: appContext
81
- } = (0, _core.useAppContext)();
77
+ const appContext = (0, _core.useAppContext)();
82
78
  const {
83
79
  appDirectory
84
80
  } = appContext;
@@ -37,9 +37,7 @@ const createServer = (ssgRoutes, apiRoutes, options, appDirectory) => new Promis
37
37
  silent: true
38
38
  });
39
39
 
40
- const {
41
- value: appContext
42
- } = (0, _core.useAppContext)();
40
+ const appContext = (0, _core.useAppContext)();
43
41
  const serverPlugins = appContext.plugins.filter(p => p.server).map(p => p.server);
44
42
  const plugins = serverPlugins.map(p => p.name);
45
43
  cp.send(JSON.stringify({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@modern-js/plugin-ssg",
3
- "version": "1.0.0-rc.4",
3
+ "version": "1.0.0-rc.9",
4
4
  "jsnext:source": "./src/index.ts",
5
5
  "types": "./dist/types/index.d.ts",
6
6
  "main": "./dist/js/node/index.js",
@@ -24,9 +24,9 @@
24
24
  },
25
25
  "dependencies": {
26
26
  "@babel/runtime": "^7",
27
- "@modern-js/babel-chain": "^1.0.0-rc.4",
28
- "@modern-js/core": "^1.0.0-rc.4",
29
- "@modern-js/utils": "^1.0.0-rc.4",
27
+ "@modern-js/babel-chain": "^1.0.0-rc.9",
28
+ "@modern-js/core": "^1.0.0-rc.9",
29
+ "@modern-js/utils": "^1.0.0-rc.9",
30
30
  "node-mocks-http": "^1.10.1",
31
31
  "normalize-path": "^3.0.0",
32
32
  "portfinder": "^1.0.28",
@@ -34,7 +34,7 @@
34
34
  "webpack-chain": "^6.5.1"
35
35
  },
36
36
  "devDependencies": {
37
- "@modern-js/server": "^1.0.0-rc.4",
37
+ "@modern-js/server": "^1.0.0-rc.9",
38
38
  "@types/jest": "^26",
39
39
  "@types/node": "^14",
40
40
  "@types/react": "^17",
@@ -42,8 +42,8 @@
42
42
  "@types/react-router": "^5.1.16",
43
43
  "@types/react-router-dom": "^5.1.8",
44
44
  "typescript": "^4",
45
- "@modern-js/plugin-testing": "^1.0.0-rc.3",
46
- "@modern-js/module-tools": "^1.0.0-rc.3"
45
+ "@modern-js/plugin-testing": "^1.0.0-rc.9",
46
+ "@modern-js/module-tools": "^1.0.0-rc.9"
47
47
  },
48
48
  "sideEffects": false,
49
49
  "modernConfig": {
@@ -51,7 +51,7 @@
51
51
  "packageMode": "node-js"
52
52
  }
53
53
  },
54
- "publicCnfig": {
54
+ "publishConfig": {
55
55
  "registry": "https://registry.npmjs.org/",
56
56
  "access": "public"
57
57
  },
package/src/index.ts CHANGED
@@ -84,9 +84,9 @@ export default createPlugin(
84
84
  // eslint-disable-next-line max-statements
85
85
  async afterBuild() {
86
86
  // eslint-disable-next-line react-hooks/rules-of-hooks
87
- const { value: resolvedConfig } = useResolvedConfigContext();
87
+ const resolvedConfig = useResolvedConfigContext();
88
88
  // eslint-disable-next-line react-hooks/rules-of-hooks
89
- const { value: appContext } = useAppContext();
89
+ const appContext = useAppContext();
90
90
 
91
91
  const { appDirectory } = appContext;
92
92
  const {
@@ -28,7 +28,7 @@ export const createServer = (
28
28
  silent: true,
29
29
  });
30
30
 
31
- const { value: appContext } = useAppContext();
31
+ const appContext = useAppContext();
32
32
  const serverPlugins = appContext.plugins
33
33
  .filter((p: any) => p.server)
34
34
  .map((p: any) => p.server);