logger icon indicating copy to clipboard operation
logger copied to clipboard

Status of this library

Open dandv opened this issue 11 months ago • 4 comments

I'm curious about the status of this library. At a first look, I see a rather glaring typo in the first paragraph of the README, then there's a section that discusses "dual stack / triple-stack integration" now that JSR allows an ESM module to be imported from Node as well. Also, it's called "colorful logger colorful logger" but doesn't have any examples of using colors? While Deno supports logging with colors natively.

dandv avatar Jan 21 '25 11:01 dandv

Thank you for your issue.

I haven't worked with Node.js since around 2020 (from 2020 to 2024, I focused on Go, and starting in 2025, I'll be working with Swift, Go, and Rust), so I'm not very familiar with this area.

ESM Module Import from Node.js

The part about allowing ESM modules to be imported from Node was completed by @UrielCh, and I still don't understand the underlying principles. You can check the related issue here:

https://github.com/deno-library/logger/issues/5

@UrielCh, could you please take a look and explain how to call this library from Node.js and the underlying principles?

Examples of Using Colors

This library internally uses "jsr:@std/[email protected]/colors," but indeed, there are no examples of using colors as you mentioned. I think this is a cool feature. For the color requirement, there are two options:

  1. You can propose a requirement along with an example of the API call, and either I or @UrielCh can handle the coding work.
  2. Given that the code for this library is quite small, you can easily add this feature yourself. If you're willing, I would be more than happy to merge it.

fuxingZhang avatar Jan 22 '25 07:01 fuxingZhang

if OpenTelemetry can replace logging and be avalable on nodeJS and Bun that will be nice.

UrielCh avatar Feb 10 '25 11:02 UrielCh

Deno console.log %c color sadly not working with nodeJS for now.

UrielCh avatar Feb 10 '25 11:02 UrielCh