You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 12, 2024. It is now read-only.
When developing i often write "$log" (or mostly "console.log" but i recently started with "$log") commands to see what my data is and if everything goes ok. So when there's something wrong i know i should debug and see what happens. Since i log a lot, the console fills up pretty fast and especially when i'm logging data being sent and received from my API.
But for the most part i'm not really interested in most $log commands if they are written with $log.log. "$log.warn" or "$log.error" are mostly interesting.
Now the "$log" command has a provider called "$logProvider" which features a setting called "debugEnabled". This turns "$log" on/off completely. But wouldn't it be nice if we could set what logs we do and do not want to see? For instance, when i'm releasing, i want to hide everything but most times i'm interested in errors or warnings.
So if we'd add a setting called "$logProvider.debugLevel" or something to set what messages to log, we'd get a proper way of filtering the messages ourselves. Perhaps you could use this to replace the "debugEnabled" setting, so we have a bit more options. An integer would probably work best for $log.log begin the lowest and $log.error being the highest.
Another thing i'm interested in: why not able users to also have an easy way for displaying $log messages on the front-end too? I cannot see the $log commands on my phone when i'm testing there.
The text was updated successfully, but these errors were encountered:
When developing i often write "$log" (or mostly "console.log" but i recently started with "$log") commands to see what my data is and if everything goes ok. So when there's something wrong i know i should debug and see what happens. Since i log a lot, the console fills up pretty fast and especially when i'm logging data being sent and received from my API.
But for the most part i'm not really interested in most $log commands if they are written with $log.log. "$log.warn" or "$log.error" are mostly interesting.
Now the "$log" command has a provider called "$logProvider" which features a setting called "debugEnabled". This turns "$log" on/off completely. But wouldn't it be nice if we could set what logs we do and do not want to see? For instance, when i'm releasing, i want to hide everything but most times i'm interested in errors or warnings.
So if we'd add a setting called "$logProvider.debugLevel" or something to set what messages to log, we'd get a proper way of filtering the messages ourselves. Perhaps you could use this to replace the "debugEnabled" setting, so we have a bit more options. An integer would probably work best for $log.log begin the lowest and $log.error being the highest.
Another thing i'm interested in: why not able users to also have an easy way for displaying $log messages on the front-end too? I cannot see the $log commands on my phone when i'm testing there.
The text was updated successfully, but these errors were encountered: