angular/projects/researchdatabox/portal-ng-common/src/lib/logger.service.ts
LoggerService
Note: The implementation is bare-boned and serves as a sort of placeholder. This will likely require a refactor as more use-cases and candidate remote backend solutions are identified.
Author: Shilo Banihit
Methods |
constructor()
|
debug |
debug(text: string, data: any)
|
Returns :
void
|
error |
error(text: string, data: any)
|
Returns :
void
|
info |
info(text: string, data: any)
|
Returns :
void
|
log |
log(text: string, data: any)
|
Returns :
void
|
import { Injectable } from '@angular/core';
/**
*
* LoggerService
*
* Note: The implementation is bare-boned and serves as a sort of placeholder. This will likely require a refactor as more use-cases and candidate remote backend solutions are identified.
*
* Author: <a href='https://github.com/shilob' target='_blank'>Shilo Banihit</a>
*
*
*/
@Injectable()
export class LoggerService {
constructor() {
}
log(text: string, data: any = undefined) {
console.log(text, data);
}
debug(text: string, data: any = undefined) {
console.debug(text, data);
}
info(text: string, data: any = undefined) {
console.info(text, data);
}
error(text: string, data: any = undefined) {
console.error(text, data);
}
}