@shuvi/platform-web 1.0.26 → 1.0.28

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.
@@ -31,10 +31,16 @@ export class ReactServerView {
31
31
  setAppError(SHUVI_ERROR.PAGE_NOT_FOUND);
32
32
  }
33
33
  if (redirected) {
34
- const { location, status } = state;
35
- return redirect(isThirdSite(location)
36
- ? location
37
- : router.resolve(location, pathname).href, status);
34
+ // handel loader redirect
35
+ if (state &&
36
+ typeof state.location === 'string') {
37
+ const { location, status } = state;
38
+ return redirect(isThirdSite(location)
39
+ ? location
40
+ : router.resolve(location, pathname).href, status);
41
+ }
42
+ // handle router internal redirect
43
+ return redirect(pathname);
38
44
  }
39
45
  const loadableModules = [];
40
46
  let htmlContent = undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shuvi/platform-web",
3
- "version": "1.0.26",
3
+ "version": "1.0.28",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/shuvijs/shuvi.git",
@@ -72,15 +72,15 @@
72
72
  },
73
73
  "dependencies": {
74
74
  "@next/react-refresh-utils": "12.1.6",
75
- "@shuvi/error-overlay": "1.0.26",
76
- "@shuvi/hook": "1.0.26",
77
- "@shuvi/platform-shared": "1.0.26",
78
- "@shuvi/router": "1.0.26",
79
- "@shuvi/router-react": "1.0.26",
80
- "@shuvi/runtime": "1.0.26",
81
- "@shuvi/shared": "1.0.26",
82
- "@shuvi/toolpack": "1.0.26",
83
- "@shuvi/utils": "1.0.26",
75
+ "@shuvi/error-overlay": "1.0.28",
76
+ "@shuvi/hook": "1.0.28",
77
+ "@shuvi/platform-shared": "1.0.28",
78
+ "@shuvi/router": "1.0.28",
79
+ "@shuvi/router-react": "1.0.28",
80
+ "@shuvi/runtime": "1.0.28",
81
+ "@shuvi/shared": "1.0.28",
82
+ "@shuvi/toolpack": "1.0.28",
83
+ "@shuvi/utils": "1.0.28",
84
84
  "content-type": "1.0.4",
85
85
  "core-js": "3.6.5",
86
86
  "doura": "0.0.11",
@@ -98,7 +98,7 @@
98
98
  "whatwg-fetch": "3.0.0"
99
99
  },
100
100
  "peerDependencies": {
101
- "@shuvi/service": "1.0.26"
101
+ "@shuvi/service": "1.0.28"
102
102
  },
103
103
  "devDependencies": {
104
104
  "@shuvi/service": "workspace:*",