All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
- Added a step in the ServerService that allow users to fully customise the body sent to the API (see example in customise doc)
- HttpClientModule is not needed by default anymore If HttpClientModule is not imported and you use the ServerSide logger, it will log an error If HttpClientModule is not imported and you use the enableSourceMaps, it will log an error
- NGXLogger is now fully customisable, see more in docs
- Column number is now displayed by default in metadata before "... [my-component.ts:15] ..." after "... [my-component.ts:15:10] ..."
- null sent in message will still log something before "this.logger.error(null, myVar)" would not log anything, now it does if you want to come back to the old behavior, you can override INGXLoggerRulesService
- LoggerConfig is renamed to INGXLoggerConfig
- NGXLogInterface is changed to INGXLoggerMetadata
- LoggerColorScheme is renamed to NGXLoggerColorScheme
- NGXMapperService is renamed to INGXLoggerMapperService
- NGXLoggerHttpService is renamed to INGXLoggerServerService
- If server logger fails it now throws an exception instead of logging an error
- LoggerUtils is deleted
- For server side logging : If an error is sent (in message or in additional) then we return the error.stack only. It was done only for message now it is also done for additional.
- NgxLoggerService is not a singleton anymore and respects Angular DI rules (before it was providedIn: 'root')
- CustomNGXLoggerService is now deprecated because the Logger is now fully customisable
- NGXLoggerMonitor is now deprecated, you should use INGXLoggerMonitor instead
- setCustomHttpHeaders is now deprecated, the property is now part of the config
- setCustomParams is now deprecated, the property is now part of the config
- setWithCredentialsOptionValue is now deprecated, the property is now part of the config
NB : those changelogs where not added correctly when the version was published, I reread all the commits to update changelog
Note about version numbers : 4.2.3 was never published (but it was commited) 4.3.1 publish was bugged and was changed for 4.3.2 right after
- NGXLoggerService is now a singleton (used with providedIn: 'root') For information, this change was reverted in 5.x.x so that the lib respects Angular DI rules and you have control on how you want to provide NGXLogger instances
- (internal) Changed the way some internal services were provided
- (internal) e2e project was deleted because it was not used
- Added forChild function to LoggerModule
- Fix for sourcemap parsing in Firefox #227. Thanks @bmtheo
- Fix for logging complex structures (circular) without introducing a new dependency #223. Thanks @bmtheo
- A new option
proxiedSteps
{number} has been introduced. When set to a number, the given number of steps will be ignored in the stacktrace to compute the caller location. If you happen to always see the same location reported in the logs (for example a wrapper service of your own), tune this option to skip this step in the stack traces #192. Thanks @amilor & @bmtheo - New config option
disableFileDetails
(defaults to false). When set totrue
, filename details will not be shown in log messages (#214). Thanks @Raphy - Calling the
debug
endpoint now useconsole.debug
api on the browser (#213). Thanks @bmtheo - Gives direct accesss to current log levels through
level()
andserverLogLevel()
. #215. Thanks @bmtheo
- Fix missing
HttpClientModule
import (#212). Thanks @markterrill - Various dependencies bumps
-
Now in order to display the messages in the debug level you need to enable “verbose” or "debug" mode in the developer tools - console of the browser.
-
Firefox – Enable debug
-
Chrome – Enable verbose
-
Edge – Enable verbose
-
Opera – Enable verbose
- Fixed issues with filename and line number being incorrect
- Now supports custom color schemes for logs (see README)
- Now support custom format timestamps in addition to pre-defined ones in Angular @qortex. Fixes #178.
- Importing mocks and the logger testing module should now be imported from the new testing entrypoint
import {LoggerTestingModule} from 'ngx-logger/testing';