@tramvai/module-child-app 2.66.3 → 2.67.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.
@@ -977,7 +977,7 @@ const browserProviders = [
977
977
  }),
978
978
  ];
979
979
 
980
- const FailedChildAppFallback = ({ name, version, tag, fallback: Fallback, }) => {
980
+ const FailedChildAppFallback = ({ config: { name, version, tag, fallback: Fallback }, }) => {
981
981
  const logger = useDi(LOGGER_TOKEN);
982
982
  const log = logger('child-app:render');
983
983
  // On client-side hydration errors will be handled in `hydrateRoot` `onRecoverableError` property,
@@ -1066,8 +1066,7 @@ const ChildApp = memo((config) => {
1066
1066
  const url = useUrl();
1067
1067
  const result = (jsx(UniversalErrorBoundary, { url: url, fallback: fallback, children: jsx(ChildAppWrapper, { ...config }) }));
1068
1068
  if (process.env.__TRAMVAI_CONCURRENT_FEATURES) {
1069
- const fallbackRender = FailedChildAppFallback(config);
1070
- return jsx(Suspense, { fallback: fallbackRender, children: result });
1069
+ return jsx(Suspense, { fallback: jsx(FailedChildAppFallback, { config: config }), children: result });
1071
1070
  }
1072
1071
  return result;
1073
1072
  });
package/lib/server.es.js CHANGED
@@ -973,7 +973,7 @@ const serverProviders = [
973
973
  }),
974
974
  ];
975
975
 
976
- const FailedChildAppFallback = ({ name, version, tag, fallback: Fallback, }) => {
976
+ const FailedChildAppFallback = ({ config: { name, version, tag, fallback: Fallback }, }) => {
977
977
  const logger = useDi(LOGGER_TOKEN);
978
978
  const log = logger('child-app:render');
979
979
  // On client-side hydration errors will be handled in `hydrateRoot` `onRecoverableError` property,
@@ -1062,8 +1062,7 @@ const ChildApp = memo((config) => {
1062
1062
  const url = useUrl();
1063
1063
  const result = (jsx(UniversalErrorBoundary, { url: url, fallback: fallback, children: jsx(ChildAppWrapper, { ...config }) }));
1064
1064
  if (process.env.__TRAMVAI_CONCURRENT_FEATURES) {
1065
- const fallbackRender = FailedChildAppFallback(config);
1066
- return jsx(Suspense, { fallback: fallbackRender, children: result });
1065
+ return jsx(Suspense, { fallback: jsx(FailedChildAppFallback, { config: config }), children: result });
1067
1066
  }
1068
1067
  return result;
1069
1068
  });
package/lib/server.js CHANGED
@@ -982,7 +982,7 @@ const serverProviders = [
982
982
  }),
983
983
  ];
984
984
 
985
- const FailedChildAppFallback = ({ name, version, tag, fallback: Fallback, }) => {
985
+ const FailedChildAppFallback = ({ config: { name, version, tag, fallback: Fallback }, }) => {
986
986
  const logger = react$1.useDi(tokensCommon.LOGGER_TOKEN);
987
987
  const log = logger('child-app:render');
988
988
  // On client-side hydration errors will be handled in `hydrateRoot` `onRecoverableError` property,
@@ -1071,8 +1071,7 @@ const ChildApp = react.memo((config) => {
1071
1071
  const url = moduleRouter.useUrl();
1072
1072
  const result = (jsxRuntime.jsx(react$1.UniversalErrorBoundary, { url: url, fallback: fallback, children: jsxRuntime.jsx(ChildAppWrapper, { ...config }) }));
1073
1073
  if (process.env.__TRAMVAI_CONCURRENT_FEATURES) {
1074
- const fallbackRender = FailedChildAppFallback(config);
1075
- return jsxRuntime.jsx(react.Suspense, { fallback: fallbackRender, children: result });
1074
+ return jsxRuntime.jsx(react.Suspense, { fallback: jsxRuntime.jsx(FailedChildAppFallback, { config: config }), children: result });
1076
1075
  }
1077
1076
  return result;
1078
1077
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tramvai/module-child-app",
3
- "version": "2.66.3",
3
+ "version": "2.67.0",
4
4
  "description": "Module for child apps",
5
5
  "browser": {
6
6
  "./lib/server.js": "./lib/browser.js",
@@ -31,21 +31,21 @@
31
31
  "@tinkoff/env-validators": "0.1.4",
32
32
  "@tinkoff/module-loader-client": "0.4.4",
33
33
  "@tinkoff/module-loader-server": "0.5.6",
34
- "@tramvai/child-app-core": "2.66.3",
35
- "@tramvai/module-router": "2.66.3",
34
+ "@tramvai/child-app-core": "2.67.0",
35
+ "@tramvai/module-router": "2.67.0",
36
36
  "@tramvai/safe-strings": "0.5.6",
37
- "@tramvai/tokens-child-app": "2.66.3"
37
+ "@tramvai/tokens-child-app": "2.67.0"
38
38
  },
39
39
  "devDependencies": {},
40
40
  "peerDependencies": {
41
41
  "@tinkoff/dippy": "0.8.12",
42
42
  "@tinkoff/utils": "^2.1.2",
43
- "@tramvai/core": "2.66.3",
44
- "@tramvai/state": "2.66.3",
45
- "@tramvai/react": "2.66.3",
46
- "@tramvai/tokens-common": "2.66.3",
47
- "@tramvai/tokens-render": "2.66.3",
48
- "@tramvai/tokens-router": "2.66.3",
43
+ "@tramvai/core": "2.67.0",
44
+ "@tramvai/state": "2.67.0",
45
+ "@tramvai/react": "2.67.0",
46
+ "@tramvai/tokens-common": "2.67.0",
47
+ "@tramvai/tokens-render": "2.67.0",
48
+ "@tramvai/tokens-router": "2.67.0",
49
49
  "react": ">=16.14.0",
50
50
  "react-dom": ">=16.14.0",
51
51
  "object-assign": "^4.1.1",