Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

debug-my-logger

panggio1ISCdeprecated1.2.0TypeScript support: included

Package no longer supported. A new package with enhanced support will be available soon.

A light logging library that enables console.log() by either a query string o a local storage flag

my-logger, npm-my-logger, debug-my-logger, arup-logger

readme

My Logger

A light and simple TypeScript logging library that enables console.log() only by either a query string o a local storage flag

Installation

npm i debug-my-logger --save

Enabling logging by querystring

Add 'myDebug' to your url querystring

e.g. 1: http://localhost?myDebug
e.g. 2: http://localhost?myDebug=123

Enabling logging by localStorage

Add 'myDebug' key to the localstorage object

localStorage.setItem("myDebug",1)

TypeScript

import { DebugLogger } from 'debug-my-logger';
DebugLogger.log("Logging test 1");
DebugLogger.log('%s, %s', var1, var2);
DebugLogger.log(`Logging test 3: ${this.properties.value1}`);