UNPKG

@200systems/mf-logger

Version:

Structured logging with multiple outputs and performance timing for TypeScript applications

13 lines 576 B
export function detectEnvironment() { const isNode = typeof process !== 'undefined' && process.versions != null && process.versions.node != null; const isBrowser = (typeof globalThis !== 'undefined' && 'window' in globalThis) || (typeof globalThis !== 'undefined' && 'document' in globalThis); const isWebWorker = typeof globalThis !== 'undefined' && 'importScripts' in globalThis && !isBrowser; return { isNode, isBrowser, isWebWorker }; } export const ENV = detectEnvironment(); //# sourceMappingURL=environment.js.map