mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-05-15 15:44:45 -04:00
Switch the base framework from Create React App to Next.JS
Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
parent
a979b6ffdd
commit
77a60c6c48
361 changed files with 5130 additions and 9605 deletions
|
@ -4,18 +4,22 @@
|
|||
* SPDX-License-Identifier: AGPL-3.0-only
|
||||
*/
|
||||
|
||||
/**
|
||||
* Checks if the current runtime is built in e2e test mode.
|
||||
*/
|
||||
export const isTestMode = (): boolean => {
|
||||
return !!process.env.REACT_APP_TEST_MODE
|
||||
return process.env.NEXT_PUBLIC_TEST_MODE === 'true'
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the current runtime should use the mocked backend.
|
||||
*/
|
||||
export const isMockMode = (): boolean => {
|
||||
return process.env.REACT_APP_BACKEND_BASE_URL === undefined
|
||||
return process.env.NEXT_PUBLIC_USE_MOCK_API === 'true'
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the current runtime was built in development mode.
|
||||
*
|
||||
* @return {@code true} if the runtime was built in development mode.
|
||||
*/
|
||||
export const isDevMode = (): boolean => {
|
||||
return process.env.NODE_ENV === 'development'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue