Skip to content

refactor: remove any in index.d.ts#325

Merged
DABH merged 2 commits intomasterfrom
unknown repository
Oct 14, 2024
Merged

refactor: remove any in index.d.ts#325
DABH merged 2 commits intomasterfrom
unknown repository

Conversation

@ghost
Copy link
Copy Markdown

@ghost ghost commented Oct 8, 2024

In TS, the any type interferes with normal type inference. It's also potentially dangerous, so I recommend using unknown. We have changed the type any in the index.d.ts file to unknown to improve the type stability of the library usage.

Copy link
Copy Markdown
Contributor

@DABH DABH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. You may want to see if there are any similar issues in winston-transport and winston. Thanks for the contribution!

@DABH DABH merged commit 55f3d8c into winstonjs:master Oct 14, 2024
@ghost ghost deleted the patch-1 branch October 14, 2024 09:40
@rojiwon123
Copy link
Copy Markdown

@DABH How long will it take for that commit to be deployed?

@DABH
Copy link
Copy Markdown
Contributor

DABH commented Nov 10, 2024

This has been released in the latest logform/winston-transport/winston versions

@ItsHarper
Copy link
Copy Markdown

This should have been considered a breaking change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants