2020-03-30 23:23:53 +00:00
|
|
|
const ENV_DEBUG = 'DEBUG';
|
|
|
|
|
2020-03-31 13:49:18 +00:00
|
|
|
/**
|
|
|
|
* Test if DEBUG mode is set.
|
|
|
|
*
|
|
|
|
* TODO: check variable value as well
|
2022-10-08 19:19:55 +00:00
|
|
|
*
|
|
|
|
* @internal
|
2020-03-31 13:49:18 +00:00
|
|
|
*/
|
2021-07-10 22:32:47 +00:00
|
|
|
export function isDebug(): boolean {
|
2020-03-30 23:23:53 +00:00
|
|
|
return Reflect.has(process.env, ENV_DEBUG);
|
2020-03-29 13:43:52 +00:00
|
|
|
}
|