Package Exports
- @micc281/tslogger
- @micc281/tslogger/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@micc281/tslogger) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
TSLogger
TSLogger is a simple logging package for writing pretty looking messages to the console. This package can also dump all the messages it needs to into a file to ensure full logging.
Usage
To use TSLogger - despite the name - you can use Javascript and Typescript.
// Info logging.
Logger.info("Hello World!");
// Warn logging.
Logger.warn("Uh-oh!");
// Error logging.
Logger.error("Some error has occured");
TSLogger allows for debug timers. This means that you can start a process then at the end of it print how long the process took to complete.
// Start some intensive process.
Logger.debugStart("complex process");
for (let i = 0; i < 10000000000000; i++) {
Logger.info(i);
}
Logger.debugEnd(); // Ends the most recent process.
// OUTPUT: Finished complex process in 15000ms