@modern-js/plugin-state 1.1.0 → 1.1.3
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 +27 -69
- package/dist/js/modern/cli/index.js +6 -2
- package/dist/js/modern/runtime/index.js +0 -4
- package/dist/js/modern/runtime/plugin.js +2 -2
- package/dist/js/modern/types.js +0 -1
- package/dist/js/node/cli/index.js +6 -2
- package/dist/js/node/runtime/index.js +0 -4
- package/dist/js/node/runtime/plugin.js +2 -2
- package/dist/js/treeshaking/cli/index.js +6 -2
- package/dist/js/treeshaking/runtime/index.js +0 -4
- package/dist/js/treeshaking/runtime/plugin.js +2 -2
- package/dist/js/treeshaking/types.js +0 -1
- package/dist/types/cli/index.d.ts +3 -0
- package/dist/types/runtime/plugin.d.ts +2 -8
- package/package.json +11 -10
- package/src/cli/index.ts +3 -0
- package/src/runtime/index.tsx +0 -5
- package/src/runtime/plugin.tsx +2 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,85 +1,43 @@
|
|
|
1
1
|
# @modern-js/plugin-state
|
|
2
2
|
|
|
3
|
-
## 1.1.
|
|
4
|
-
|
|
5
|
-
### Minor Changes
|
|
6
|
-
|
|
7
|
-
- 96119db2: Relese v1.1.0
|
|
8
|
-
|
|
9
|
-
1. 全面支持 Windows 平台
|
|
10
|
-
|
|
11
|
-
ISSUE:
|
|
12
|
-
|
|
13
|
-
- [182](https://github.com/modern-js-dev/modern.js/issues/182)
|
|
14
|
-
- [236](https://github.com/modern-js-dev/modern.js/issues/236)
|
|
15
|
-
|
|
16
|
-
PR
|
|
17
|
-
|
|
18
|
-
- [219](https://github.com/modern-js-dev/modern.js/pull/219)
|
|
19
|
-
- [247](https://github.com/modern-js-dev/modern.js/pull/247)
|
|
20
|
-
- [249](https://github.com/modern-js-dev/modern.js/pull/249)
|
|
21
|
-
- [253](https://github.com/modern-js-dev/modern.js/pull/253)
|
|
22
|
-
- [268](https://github.com/modern-js-dev/modern.js/pull/268)
|
|
23
|
-
- [270](https://github.com/modern-js-dev/modern.js/pull/270)
|
|
24
|
-
- [273](https://github.com/modern-js-dev/modern.js/pull/273)
|
|
25
|
-
- [276](https://github.com/modern-js-dev/modern.js/pull/276)
|
|
26
|
-
|
|
27
|
-
2. 修复 Unbundled 模式启用问题
|
|
28
|
-
|
|
29
|
-
ISSUE
|
|
30
|
-
|
|
31
|
-
- [186](https://github.com/modern-js-dev/modern.js/issues/186)
|
|
32
|
-
- [224](https://github.com/modern-js-dev/modern.js/issues/224)
|
|
33
|
-
- [225](https://github.com/modern-js-dev/modern.js/issues/225)
|
|
34
|
-
- [238](https://github.com/modern-js-dev/modern.js/issues/238)
|
|
35
|
-
|
|
36
|
-
PR
|
|
37
|
-
|
|
38
|
-
- [226](https://github.com/modern-js-dev/modern.js/pull/226)
|
|
39
|
-
- [264](https://github.com/modern-js-dev/modern.js/pull/264)
|
|
40
|
-
- [codesmith-12](https://github.com/modern-js-dev/codesmith/pull/12)
|
|
3
|
+
## 1.1.3
|
|
41
4
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
ISSUE
|
|
45
|
-
|
|
46
|
-
- [198](https://github.com/modern-js-dev/modern.js/issues/198)
|
|
47
|
-
|
|
48
|
-
PR
|
|
49
|
-
|
|
50
|
-
- [209](https://github.com/modern-js-dev/modern.js/pull/209)
|
|
51
|
-
|
|
52
|
-
4. 修复 Storybook 使用时浏览器打开页面报错
|
|
53
|
-
|
|
54
|
-
ISSUE
|
|
55
|
-
|
|
56
|
-
- [228](https://github.com/modern-js-dev/modern.js/issues/228)
|
|
57
|
-
|
|
58
|
-
PR
|
|
59
|
-
|
|
60
|
-
- [254](https://github.com/modern-js-dev/modern.js/pull/254)
|
|
5
|
+
### Patch Changes
|
|
61
6
|
|
|
62
|
-
|
|
7
|
+
- 4406c2db: fix: avoid fetching data again when ssr succeeds
|
|
8
|
+
- Updated dependencies [90eeb72c]
|
|
9
|
+
- Updated dependencies [e04914ce]
|
|
10
|
+
- Updated dependencies [4406c2db]
|
|
11
|
+
- Updated dependencies [5a4c557e]
|
|
12
|
+
- Updated dependencies [e04914ce]
|
|
13
|
+
- Updated dependencies [ecb344dc]
|
|
14
|
+
- @modern-js/core@1.2.0
|
|
15
|
+
- @modern-js/runtime-core@1.1.2
|
|
63
16
|
|
|
64
|
-
|
|
17
|
+
## 1.1.2
|
|
65
18
|
|
|
66
|
-
|
|
67
|
-
- [257](https://github.com/modern-js-dev/modern.js/issues/257)
|
|
19
|
+
### Patch Changes
|
|
68
20
|
|
|
69
|
-
|
|
21
|
+
- 0fa83663: support more .env files
|
|
22
|
+
- f594fbc8: fix apple icon and favicon support
|
|
23
|
+
- Updated dependencies [6f7fe574]
|
|
24
|
+
- Updated dependencies [0fa83663]
|
|
25
|
+
- @modern-js/core@1.1.2
|
|
26
|
+
- @modern-js/runtime-core@1.1.1
|
|
70
27
|
|
|
71
|
-
|
|
72
|
-
- [271](https://github.com/modern-js-dev/modern.js/pull/271)
|
|
28
|
+
## 1.1.1
|
|
73
29
|
|
|
74
|
-
|
|
30
|
+
### Patch Changes
|
|
75
31
|
|
|
76
|
-
|
|
32
|
+
- 725c4ff0: fix(state): type error when build @modern-js/plugin-state was fixed
|
|
33
|
+
- Updated dependencies [687c92c7]
|
|
34
|
+
- @modern-js/core@1.1.1
|
|
77
35
|
|
|
78
|
-
|
|
36
|
+
## 1.1.0
|
|
79
37
|
|
|
80
|
-
|
|
38
|
+
### Minor Changes
|
|
81
39
|
|
|
82
|
-
|
|
40
|
+
- 96119db2: Relese v1.1.0
|
|
83
41
|
|
|
84
42
|
### Patch Changes
|
|
85
43
|
|
|
@@ -31,8 +31,12 @@ const index = createPlugin(() => {
|
|
|
31
31
|
entryName
|
|
32
32
|
} = entrypoint; // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
33
33
|
|
|
34
|
-
const userConfig = useResolvedConfigContext();
|
|
35
|
-
|
|
34
|
+
const userConfig = useResolvedConfigContext(); // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
35
|
+
|
|
36
|
+
const {
|
|
37
|
+
packageName
|
|
38
|
+
} = useAppContext();
|
|
39
|
+
const stateConfig = (_getEntryOptions = getEntryOptions(entryName, userConfig.runtime, userConfig.runtimeByEntries, packageName)) === null || _getEntryOptions === void 0 ? void 0 : _getEntryOptions.state;
|
|
36
40
|
stateConfigMap.set(entryName, stateConfig);
|
|
37
41
|
|
|
38
42
|
const getEnabledPlugins = () => {
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
/// <reference types="@modern-js-reduck/plugin-auto-actions" />
|
|
2
|
-
/// <reference types="@modern-js-reduck/plugin-devtools" />
|
|
3
|
-
/// <reference types="@modern-js-reduck/plugin-effects" />
|
|
4
|
-
/// <reference types="@modern-js-reduck/plugin-immutable" />
|
|
5
1
|
// eslint-disable-next-line filenames/match-exported
|
|
6
2
|
import statePlugin from "./plugin";
|
|
7
3
|
export * from '@modern-js-reduck/react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
1
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
2
2
|
|
|
3
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
4
|
|
|
5
5
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
6
6
|
|
package/dist/js/modern/types.js
CHANGED
|
@@ -46,8 +46,12 @@ const index = (0, _core.createPlugin)(() => {
|
|
|
46
46
|
entryName
|
|
47
47
|
} = entrypoint; // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
48
48
|
|
|
49
|
-
const userConfig = (0, _core.useResolvedConfigContext)();
|
|
50
|
-
|
|
49
|
+
const userConfig = (0, _core.useResolvedConfigContext)(); // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
50
|
+
|
|
51
|
+
const {
|
|
52
|
+
packageName
|
|
53
|
+
} = (0, _core.useAppContext)();
|
|
54
|
+
const stateConfig = (_getEntryOptions = (0, _utils.getEntryOptions)(entryName, userConfig.runtime, userConfig.runtimeByEntries, packageName)) === null || _getEntryOptions === void 0 ? void 0 : _getEntryOptions.state;
|
|
51
55
|
stateConfigMap.set(entryName, stateConfig);
|
|
52
56
|
|
|
53
57
|
const getEnabledPlugins = () => {
|
|
@@ -55,10 +55,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
|
|
|
55
55
|
|
|
56
56
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || typeof obj !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
57
57
|
|
|
58
|
-
/// <reference types="@modern-js-reduck/plugin-auto-actions" />
|
|
59
|
-
/// <reference types="@modern-js-reduck/plugin-devtools" />
|
|
60
|
-
/// <reference types="@modern-js-reduck/plugin-effects" />
|
|
61
|
-
/// <reference types="@modern-js-reduck/plugin-immutable" />
|
|
62
58
|
// eslint-disable-next-line filenames/match-exported
|
|
63
59
|
var _default = _plugin.default;
|
|
64
60
|
exports.default = _default;
|
|
@@ -30,9 +30,9 @@ Object.keys(_plugins).forEach(function (key) {
|
|
|
30
30
|
});
|
|
31
31
|
});
|
|
32
32
|
|
|
33
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
33
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
34
34
|
|
|
35
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
35
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
36
36
|
|
|
37
37
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
38
38
|
|
|
@@ -27,8 +27,12 @@ var index = createPlugin(function () {
|
|
|
27
27
|
imports = _ref.imports;
|
|
28
28
|
var entryName = entrypoint.entryName; // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
29
29
|
|
|
30
|
-
var userConfig = useResolvedConfigContext();
|
|
31
|
-
|
|
30
|
+
var userConfig = useResolvedConfigContext(); // eslint-disable-next-line react-hooks/rules-of-hooks
|
|
31
|
+
|
|
32
|
+
var _useAppContext = useAppContext(),
|
|
33
|
+
packageName = _useAppContext.packageName;
|
|
34
|
+
|
|
35
|
+
var stateConfig = (_getEntryOptions = getEntryOptions(entryName, userConfig.runtime, userConfig.runtimeByEntries, packageName)) === null || _getEntryOptions === void 0 ? void 0 : _getEntryOptions.state;
|
|
32
36
|
stateConfigMap.set(entryName, stateConfig);
|
|
33
37
|
|
|
34
38
|
var getEnabledPlugins = function getEnabledPlugins() {
|
|
@@ -1,7 +1,3 @@
|
|
|
1
|
-
/// <reference types="@modern-js-reduck/plugin-auto-actions" />
|
|
2
|
-
/// <reference types="@modern-js-reduck/plugin-devtools" />
|
|
3
|
-
/// <reference types="@modern-js-reduck/plugin-effects" />
|
|
4
|
-
/// <reference types="@modern-js-reduck/plugin-immutable" />
|
|
5
1
|
// eslint-disable-next-line filenames/match-exported
|
|
6
2
|
import statePlugin from "./plugin";
|
|
7
3
|
export * from '@modern-js-reduck/react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
1
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
2
2
|
|
|
3
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
3
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
4
4
|
|
|
5
5
|
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
6
6
|
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
declare const index: import("@modern-js/core").AsyncPlugin<Partial<import("@modern-js/core").Progresses2Threads<{
|
|
2
2
|
config: import("@modern-js/core").ParallelWorkflow<void, unknown>;
|
|
3
|
+
resolvedConfig: import("@modern-js/core").AsyncWaterfall<{
|
|
4
|
+
resolved: import("@modern-js/core").NormalizedConfig;
|
|
5
|
+
}>;
|
|
3
6
|
validateSchema: import("@modern-js/core").ParallelWorkflow<void, unknown>;
|
|
4
7
|
prepare: import("@modern-js/core").AsyncWorkflow<void, void>;
|
|
5
8
|
commands: import("@modern-js/core").AsyncWorkflow<{
|
|
@@ -7,14 +7,8 @@ declare module '@modern-js/runtime-core' {
|
|
|
7
7
|
interface TRuntimeContext {
|
|
8
8
|
store: Store;
|
|
9
9
|
}
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
interface Window {
|
|
13
|
-
_SSR_DATA?: {
|
|
14
|
-
data: {
|
|
15
|
-
storeState: any;
|
|
16
|
-
};
|
|
17
|
-
};
|
|
10
|
+
interface SSRData {
|
|
11
|
+
storeState: any;
|
|
18
12
|
}
|
|
19
13
|
}
|
|
20
14
|
declare type PluginProps = Parameters<typeof createStore>[0];
|
package/package.json
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
"modern",
|
|
12
12
|
"modern.js"
|
|
13
13
|
],
|
|
14
|
-
"version": "1.1.
|
|
14
|
+
"version": "1.1.3",
|
|
15
15
|
"jsnext:source": "./src/index.ts",
|
|
16
16
|
"types": "./dist/types/runtime/index.d.ts",
|
|
17
17
|
"main": "./dist/js/node/runtime/index.js",
|
|
@@ -56,23 +56,23 @@
|
|
|
56
56
|
"redux-logger": "^3.0.6"
|
|
57
57
|
},
|
|
58
58
|
"devDependencies": {
|
|
59
|
-
"@modern-js/core": "^1.
|
|
60
|
-
"@modern-js/plugin": "^1.1.
|
|
61
|
-
"@modern-js/runtime-core": "^1.1.
|
|
62
|
-
"@modern-js/utils": "^1.1.
|
|
59
|
+
"@modern-js/core": "^1.2.0",
|
|
60
|
+
"@modern-js/plugin": "^1.1.2",
|
|
61
|
+
"@modern-js/runtime-core": "^1.1.2",
|
|
62
|
+
"@modern-js/utils": "^1.1.5",
|
|
63
63
|
"@types/jest": "^26",
|
|
64
64
|
"@types/node": "^14",
|
|
65
65
|
"@types/react": "^17",
|
|
66
66
|
"@types/react-dom": "^17",
|
|
67
67
|
"react": "^17.0.2",
|
|
68
68
|
"typescript": "^4",
|
|
69
|
-
"@modern-js/plugin-testing": "^1.
|
|
70
|
-
"@modern-js/module-tools": "^1.
|
|
69
|
+
"@modern-js/plugin-testing": "^1.1.1",
|
|
70
|
+
"@modern-js/module-tools": "^1.1.2"
|
|
71
71
|
},
|
|
72
72
|
"sideEffects": false,
|
|
73
73
|
"peerDependencies": {
|
|
74
|
-
"@modern-js/core": "^1.
|
|
75
|
-
"@modern-js/runtime-core": "^1.1.
|
|
74
|
+
"@modern-js/core": "^1.2.0",
|
|
75
|
+
"@modern-js/runtime-core": "^1.1.2",
|
|
76
76
|
"react": "^17.0.2"
|
|
77
77
|
},
|
|
78
78
|
"modernConfig": {},
|
|
@@ -84,5 +84,6 @@
|
|
|
84
84
|
"new": "modern new",
|
|
85
85
|
"build": "modern build",
|
|
86
86
|
"test": "modern test --passWithNoTests"
|
|
87
|
-
}
|
|
87
|
+
},
|
|
88
|
+
"readme": "\n<p align=\"center\">\n <a href=\"https://modernjs.dev\" target=\"blank\"><img src=\"https://lf3-static.bytednsdoc.com/obj/eden-cn/ylaelkeh7nuhfnuhf/modernjs-cover.png\" width=\"300\" alt=\"Modern.js Logo\" /></a>\n</p>\n<p align=\"center\">\n现代 Web 工程体系\n <br/>\n <a href=\"https://modernjs.dev\" target=\"blank\">\n modernjs.dev\n </a>\n</p>\n<p align=\"center\">\n The meta-framework suite designed from scratch for frontend-focused modern web development\n</p>\n\n# Introduction\n\n> The doc site ([modernjs.dev](https://modernjs.dev)) and articles are only available in Chinese for now, we are planning to add English versions soon.\n\n- [Modern.js: Hello, World!](https://zhuanlan.zhihu.com/p/426707646)\n\n## Getting Started\n\n- [Quick Start](https://modernjs.dev/docs/start)\n- [Guides](https://modernjs.dev/docs/guides)\n- [API References](https://modernjs.dev/docs/apis)\n\n## Contributing\n\n- [Contributing Guide](https://github.com/modern-js-dev/modern.js/blob/main/CONTRIBUTING.md)\n"
|
|
88
89
|
}
|
package/src/cli/index.ts
CHANGED
|
@@ -42,11 +42,14 @@ const index = createPlugin(
|
|
|
42
42
|
const { entryName } = entrypoint;
|
|
43
43
|
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
44
44
|
const userConfig = useResolvedConfigContext();
|
|
45
|
+
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
46
|
+
const { packageName } = useAppContext();
|
|
45
47
|
|
|
46
48
|
const stateConfig = getEntryOptions(
|
|
47
49
|
entryName,
|
|
48
50
|
userConfig.runtime,
|
|
49
51
|
userConfig.runtimeByEntries,
|
|
52
|
+
packageName,
|
|
50
53
|
)?.state;
|
|
51
54
|
|
|
52
55
|
stateConfigMap.set(entryName, stateConfig);
|
package/src/runtime/index.tsx
CHANGED
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
/// <reference types="@modern-js-reduck/plugin-auto-actions" />
|
|
2
|
-
/// <reference types="@modern-js-reduck/plugin-devtools" />
|
|
3
|
-
/// <reference types="@modern-js-reduck/plugin-effects" />
|
|
4
|
-
/// <reference types="@modern-js-reduck/plugin-immutable" />
|
|
5
|
-
|
|
6
1
|
// eslint-disable-next-line filenames/match-exported
|
|
7
2
|
import statePlugin from './plugin';
|
|
8
3
|
|
package/src/runtime/plugin.tsx
CHANGED
|
@@ -12,15 +12,9 @@ declare module '@modern-js/runtime-core' {
|
|
|
12
12
|
interface TRuntimeContext {
|
|
13
13
|
store: Store;
|
|
14
14
|
}
|
|
15
|
-
}
|
|
16
15
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
_SSR_DATA?: {
|
|
20
|
-
data: {
|
|
21
|
-
storeState: any;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
16
|
+
interface SSRData {
|
|
17
|
+
storeState: any;
|
|
24
18
|
}
|
|
25
19
|
}
|
|
26
20
|
|