esoftplay 0.0.123-d → 0.0.123-e
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/modules/user/index.tsx +4 -3
- package/package.json +1 -1
- package/publisher.js +0 -1
package/modules/user/index.tsx
CHANGED
|
@@ -16,6 +16,7 @@ import { UserClass } from 'esoftplay/cache/user/class/import';
|
|
|
16
16
|
import { UserHook } from 'esoftplay/cache/user/hook/import';
|
|
17
17
|
import { UserLoading } from 'esoftplay/cache/user/loading/import';
|
|
18
18
|
import { UserRoutes } from 'esoftplay/cache/user/routes/import';
|
|
19
|
+
import useGlobalState from 'esoftplay/global';
|
|
19
20
|
import Worker from 'esoftplay/libs/worker';
|
|
20
21
|
import _global from 'esoftplay/_global';
|
|
21
22
|
import * as Font from "expo-font";
|
|
@@ -57,20 +58,20 @@ function isWorkerReady(onReady: () => void): void {
|
|
|
57
58
|
}
|
|
58
59
|
|
|
59
60
|
|
|
60
|
-
|
|
61
|
+
const route = useGlobalState<any>(undefined, { persistKey: 'user_index_routes_initial' })
|
|
61
62
|
export default function m(props: UserIndexProps): any {
|
|
62
63
|
const [loading, setLoading] = useSafeState(true)
|
|
63
64
|
const user = UserClass.state().useSelector(s => s)
|
|
64
65
|
const ready = React.useRef(0)
|
|
65
66
|
UseDeeplink()
|
|
66
67
|
//@ts-ignore
|
|
67
|
-
const initialState = __DEV__ ?
|
|
68
|
+
const initialState = __DEV__ ? route.get() : undefined
|
|
68
69
|
|
|
69
70
|
function handler(currentState: any): void {
|
|
70
71
|
//@ts-ignore
|
|
71
72
|
if (__DEV__) {
|
|
72
73
|
//@ts-ignore
|
|
73
|
-
|
|
74
|
+
route.set(currentState)
|
|
74
75
|
}
|
|
75
76
|
UserRoutes.set(currentState)
|
|
76
77
|
}
|
package/package.json
CHANGED
package/publisher.js
CHANGED