Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SetFieldType: Add option to preserve property modifiers #1017

Conversation

som-sm
Copy link
Collaborator

@som-sm som-sm commented Dec 21, 2024

Fixes: #1016

Adds a new preservePropertyModifiers option.

I've set the default value of this option to true, which means it'll regress from the existing behaviour, but that should be fine if the current behaviour is considered a bug.

@som-sm som-sm changed the title Fix/preserve property modifier in set field type SetFieldType: Add option to preserve property modifiers Dec 21, 2024
@som-sm
Copy link
Collaborator Author

som-sm commented Dec 21, 2024

@sindresorhus Noticed there's some room for improvement with index signatures as well. I'll create a separate PR for that because that'll require more complicated changes, so it's better to keep those changes separate.

@sindresorhus sindresorhus merged commit 59517cb into sindresorhus:main Dec 25, 2024
11 checks passed
@sindresorhus
Copy link
Owner

Nice 👍

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.

SetFieldType bug
2 participants