Open Hilzu opened 7 years ago
Awesome, thanks for contributing! I'm happy with this change since it improves contrast and readability.
The only thing I'm worried about is that this is technically a breaking change. I'd love to merge it soon, but I have some more breaking changes in mind for express-winston v3. I think I'm going to hold off for now, but I may end up changing my mind later just to get this in. 🙂
Would you also consider matching expressFormat
with morgan in v3? Currently it matches the morgan dev
format but it's missing content length from the end. I can create a PR if you agree that it should be done.
@Hilzu Sorry, responding very late.
I'm torn on adding the content length to be on by default with expressFormat
. I started writing a longer response but ended up deleting it (that's how torn I am).
I'm good with adding content length to expressFormat
, but I'm inclined to hold off on that until a v3 release as well. I know it's kind of pedantic, but I don't really want to mess with the log formats of people's files without a major version bump.
This is a very old PR. What are we doing with this?
Morgan only colors the status code in the log message according to code, documentation and quick testing. This PR makes the log output when using the
colorize
option to match it. IMHO this also makes the output a lot more readable because the current setting of grey on black has really low contrast with many color themes.