cabinjs / axe

:axe: Logger-agnostic wrapper that normalizes logs regardless of arg style. Great for large dev teams, old/new projects, and works w/Pino, Bunyan, Winston, console, and more. It is lightweight, performant, highly-configurable, and automatically adds OS, CPU, and Git information to your logs. Hooks, dot-notation remap, omit, and pick of metadata.
https://forwardemail.net/docs/best-practices-for-node-js-logging
MIT License
50 stars 11 forks source link

feat: add types and fix minor bug #16

Closed shadowgate15 closed 5 months ago

shadowgate15 commented 5 months ago

First and foremost this adds TypeScript types.

Second, I noticed a minor bug in making sure that all necessary methods on the logger was set to functions. If a logger was passed in with a field of 'log', for example, that was set to a non-nullish value but was not a function, Axe could attempt to set another required field to that value. This causes errors when that function is needed.

Checklist

shadowgate15 commented 5 months ago

@titanism it looks like xo version 0.57.0 bumped to require node 18. How would you like to proceed?

titanism commented 5 months ago

I will require node v18 and major bump

titanism commented 5 months ago

Actually, just will stick to v0.56 for now.

titanism commented 5 months ago

I think we need to add to files the types

titanism commented 5 months ago

done https://github.com/cabinjs/axe/commit/18793841c8c64ecdb5c4b561f1c150b1be03c6b4

titanism commented 5 months ago

v12.2.4 released, thanks @shadowgate15 🙏 🚀

https://github.com/cabinjs/axe/releases/tag/v12.2.4

also I dropped node v14 and node v16 from CI tests in workflow CI yml file - thanks for that tip @shadowgate15