12345678910111213 |
- import store from '@/store'
- import storage from '@/utils/storage'
- import { getPlatform } from '@/utils/app'
- import { ACCESS_TOKEN, USER_ID } from '@/store/mutation-types'
- export default function Initializer() {
-
- store.commit('SET_PLATFORM', getPlatform())
-
- store.commit('SET_TOKEN', storage.get(ACCESS_TOKEN))
-
- store.commit('SET_USER_ID', storage.get(USER_ID))
- }
|