new Logger()
Enable / disable logging across various environment new Logger().setlevel(level) where level are :-
- 1 -> All console methods are enabled.
- 2 -> console log and info methods are diabled while other works as expected
- 3 -> console.error method will be enabled while other are disabled
- 4 -> All console methods are disabled
Methods
-
setlevel( [key])
-
Set logger level
Parameters:
Name Type Argument Default Description key
number <optional>
this.info logging level