mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-09 13:51:57 -04:00

Some checks failed
Docker / build-and-push (backend) (push) Has been cancelled
Docker / build-and-push (frontend) (push) Has been cancelled
E2E Tests / backend-sqlite (push) Has been cancelled
E2E Tests / backend-mariadb (push) Has been cancelled
E2E Tests / backend-postgres (push) Has been cancelled
E2E Tests / Build test build of frontend (push) Has been cancelled
Lint and check format / Lint files and check formatting (push) Has been cancelled
REUSE Compliance Check / reuse (push) Has been cancelled
Scorecard supply-chain security / Scorecard analysis (push) Has been cancelled
Static Analysis / Njsscan code scanning (push) Has been cancelled
Static Analysis / CodeQL analysis (push) Has been cancelled
Run tests & build / Test and build with NodeJS 20 (push) Has been cancelled
E2E Tests / frontend-cypress (1) (push) Has been cancelled
E2E Tests / frontend-cypress (2) (push) Has been cancelled
E2E Tests / frontend-cypress (3) (push) Has been cancelled
Co-authored-by: Philip Molares <philip.molares@udo.edu> Signed-off-by: Erik Michelson <github@erik.michelson.eu> Signed-off-by: Philip Molares <philip.molares@udo.edu>
33 lines
1.1 KiB
TypeScript
33 lines
1.1 KiB
TypeScript
/*
|
|
* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
|
*
|
|
* SPDX-License-Identifier: AGPL-3.0-only
|
|
*/
|
|
import { isDevMode } from '../utils/test-modes'
|
|
import { configureStore } from '@reduxjs/toolkit'
|
|
import { darkModeReducer } from './dark-mode/slice'
|
|
import { editorConfigReducer } from './editor-config/slice'
|
|
import { userReducer } from './user/slice'
|
|
import { rendererStatusReducer } from './renderer-status/slice'
|
|
import { realtimeStatusReducer } from './realtime/slice'
|
|
import { historyReducer } from './history/slice'
|
|
import { noteDetailsReducer } from './note-details/slice'
|
|
import { printModeReducer } from './print-mode/slice'
|
|
|
|
export const store = configureStore({
|
|
reducer: {
|
|
darkMode: darkModeReducer,
|
|
editorConfig: editorConfigReducer,
|
|
user: userReducer,
|
|
rendererStatus: rendererStatusReducer,
|
|
realtimeStatus: realtimeStatusReducer,
|
|
history: historyReducer,
|
|
noteDetails: noteDetailsReducer,
|
|
printMode: printModeReducer
|
|
},
|
|
devTools: isDevMode
|
|
})
|
|
|
|
export type ApplicationState = ReturnType<typeof store.getState>
|
|
|
|
export const getGlobalState = (): ApplicationState => store.getState()
|