@cmolina/log
Keep track for when functions are being called and when they returned.
Quickstart
Install the dependency
npm i -D @cmolina/log
Log your functions
;; // 1. wrap your function; // 2. use your wrapped function as expectedmyFunctionWithLogs'pass', 'the', 'original', 'parameters'; // 3. see the logs in your console!/* myFunction('pass', 'the', 'original', 'parameters') started myFunction('pass', 'the', 'original', 'parameters') returned '😁'*/
Log your methods
;; ; // 1. wrap your instance; // 2. use your wrapped method as expectedmyInstanceWithLogs.myMethod'pass', 'the', 'original', 'parameters'; // 3. see the logs in your console!/* MyClass.myMethod('pass', 'the', 'original', 'parameters') started MyClass.myMethod('pass', 'the', 'original', 'parameters') returned '😲'*/