aboutsummaryrefslogtreecommitdiff
path: root/modern/src/store/session.js
diff options
context:
space:
mode:
Diffstat (limited to 'modern/src/store/session.js')
-rw-r--r--modern/src/store/session.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/modern/src/store/session.js b/modern/src/store/session.js
new file mode 100644
index 00000000..772368c4
--- /dev/null
+++ b/modern/src/store/session.js
@@ -0,0 +1,16 @@
+import { createSlice } from '@reduxjs/toolkit';
+
+const { reducer, actions } = createSlice({
+ name: 'session',
+ initialState: {
+ authenticated: false,
+ },
+ reducers: {
+ authenticated(state, action) {
+ state.authenticated = action.payload;
+ },
+ }
+});
+
+export { actions as sessionActions };
+export { reducer as sessionReducer };