console statement standardization
Status
Accepted.
Context
In production environments it may seem unclear if an error or warning message is shown in the console from which part of the application they occurred.
Decision
All console.warn and console.error messages have to show the application's part in which they are invoked.
We add the location to the console messages at compile-time using Vite.
Consequences
- (+) Errors and warnings can more easily be tracked back to the place in which they occur.
- (+) This restriction is enforced automatically.
- (-) Console messages are more verbose.