Skip to content

Releases: PGTBoos/RxJs-Debug.ts

debug functions got extra overrides

01 Aug 07:30
0acf6f2
Compare
Choose a tag to compare

When your fixing an angular project upgrade.
At some point you will debug a lot, and then it would be handy to know where those messages came from
There is now a prefix optional to provide a callerInfo string (it can again be disabled in theRxjs-Debug.ts by a boolean.)
You dont have to provide it but now you can write down something alike 'myfile-functionX' or so.

ConsoleLog and vebose logging RxJsDebug

31 Jul 12:09
66fd70f
Compare
Choose a tag to compare

Added ConsoleLog
This can be used as a replacement for console.log
It works just as console.log, but only outputs in development mode, and if a local variable is set to true (ea this.verbose)
Note that it is not my goal to ban console.log but this allows to enable extra logging on a per file basis (bug cases).

ConsoleLog(this.verbose, 'anything like you did before with console', showVarsEtc, anotherVar);`

Updated RxJsDebug
RxJs can be turned of globally within the RxJs-Debug.ts file, but now by use of an override it can also be controled by a verbose value.
I think this is a handy update as RXJS typically concerns serveral areas within an app and you might not want to get logging from all of them.

 .pipe( RxJsDebug(  RxJsLoggingLevel.INFO, 'Edit mode:' ));
 
 //There is also a overload to use a verbose boolean, that then also should be true (for per file debugging)
 .pipe( RxJsDebug(this.verbose, RxJsLoggingLevel.INFO, 'Edit mode:' ));
 
 //And if you want to see a stack trace as well add a boolean true at the end of RxJsDebug
 .pipe( RxJsDebug(this.verbose, RxJsLoggingLevel.INFO, 'Edit mode:' , true));

(while writing i wonder if we should put a Force boolean too, to enforce logging of all under debug, ... if people want it drop me an issue)

Added a state log service

29 Jul 10:28
9b01388
Compare
Choose a tag to compare

This version adds a new state log service.

You can make use of, you dont have to use it
It might be of help it if the other tool rxjsDebug isn't enough to tackle the problems your facing