mirror of
https://github.com/MrUnknownDE/panel.git
synced 2026-04-18 22:33:44 +02:00
Plop user data into the store when loading up the base component
This commit is contained in:
11
resources/scripts/state/models/user.ts
Normal file
11
resources/scripts/state/models/user.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import { UserState } from '@/state/types';
|
||||
import { action } from 'easy-peasy';
|
||||
|
||||
const user: UserState = {
|
||||
data: undefined,
|
||||
setUserData: action((state, payload) => {
|
||||
state.data = payload;
|
||||
}),
|
||||
};
|
||||
|
||||
export default user;
|
||||
Reference in New Issue
Block a user