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
So if you just wanted to write something indicating a successful operation, regular console.log is basically what that is for (due to default formatting and lack of scary warning/error formatting). I think there is more of a need to indicate that something went wrong, as opposed to right.
However if you wanted to improve that look, I think the best thing to do here is use something custom like the following (but a bit more generalized etc):
This will work in browsers, but not node (sadly we haven't gotten around to exactly specifying how the %cCSS format specifier should work, though browsers support it).
Furthermore, we couldn't really specify something the color green for console.success in this standard, as there's no history of this (or really any) standard specifying the UX bits of API results. This seems like something that could be abstracted over by a library or something, and might be less appropriate for this spec.
Is your feature request related to a problem? Please describe.
Just like console.error, we need a console.success.
Describe the solution you'd like
When console.success is used, I would like to see output it in green colour.
Describe alternatives you've considered
Current workaround I have is to do console.log("Success: Order post is successful").
This will improve the confidence, way better than console.error.
The text was updated successfully, but these errors were encountered: