@yeeyoon/library 2.8.2 → 2.8.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.
@@ -7,7 +7,14 @@ import { notification } from 'antd';
7
7
  const TOKEN_KEY = 'X-Auth-Token';
8
8
  const ID_KEY = 'X-Auth-Id';
9
9
  const REST_KEY = 'Login-Rest-Info';
10
- const qsData = qs.parse(window.location.search.slice(1));
10
+ const { search, hash } = window.location;
11
+ let searchQs = '';
12
+ if (search !== '') {
13
+ searchQs = search.slice(1);
14
+ } else if (hash !== '') {
15
+ searchQs = hash.split('?')[1];
16
+ }
17
+ const qsData = qs.parse(searchQs);
11
18
  const { token, userId, ...rest } = qsData;
12
19
 
13
20
  token && ls.set(TOKEN_KEY, token);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yeeyoon/library",
3
- "version": "2.8.2",
3
+ "version": "2.8.3",
4
4
  "description": "宜云前端组件库和通用服务",
5
5
  "main": "index.js",
6
6
  "repository": {