Skip to content

Replacing any with unknown in the ReadonlyArray type declaration.#2241

Merged
gzm0 merged 2 commits intoopenapi-ts:mainfrom
stanleyk:readonlyarray-any-to-unknown
Apr 3, 2025
Merged

Replacing any with unknown in the ReadonlyArray type declaration.#2241
gzm0 merged 2 commits intoopenapi-ts:mainfrom
stanleyk:readonlyarray-any-to-unknown

Conversation

@stanleyk
Copy link
Copy Markdown
Contributor

@stanleyk stanleyk commented Apr 2, 2025

Changes

The current declaration of the enhanced ReadonlyArray type uses the undesired any type instead of the more appropriate unknown type.

  • Unit tests updated
  • docs/ updated (if necessary)
  • pnpm run update:examples run (only applicable for openapi-typescript)

@stanleyk stanleyk requested a review from a team as a code owner April 2, 2025 20:31
@stanleyk stanleyk requested a review from gzm0 April 2, 2025 20:31
@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 2, 2025

Deploy Preview for openapi-ts failed.

Name Link
🔨 Latest commit 2ebb6c1
🔍 Latest deploy log https://app.netlify.com/projects/openapi-ts/deploys/67ee7d61824dff0008e8f412

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Apr 2, 2025

🦋 Changeset detected

Latest commit: 2ebb6c1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
openapi-typescript Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Copy Markdown
Contributor

@gzm0 gzm0 left a comment

Choose a reason for hiding this comment

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

Heya! Thanks a lot for the contribution. Definitely happy to see all these any's go :)

@stanleyk
Copy link
Copy Markdown
Contributor Author

stanleyk commented Apr 3, 2025

Thanks, @gzm0 , I have added the changeset. You are right, this should not break anything.

Copy link
Copy Markdown
Contributor

@gzm0 gzm0 left a comment

Choose a reason for hiding this comment

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

LGTM! TY!

@gzm0 gzm0 merged commit ef23947 into openapi-ts:main Apr 3, 2025
8 checks passed
@openapi-ts-bot openapi-ts-bot mentioned this pull request Apr 2, 2025
@stanleyk stanleyk deleted the readonlyarray-any-to-unknown branch April 3, 2025 13:02
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.

2 participants