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

Enable "exactOptionalPropertyTypes" flag #21

Open
Gudahtt opened this issue Apr 22, 2022 · 0 comments
Open

Enable "exactOptionalPropertyTypes" flag #21

Gudahtt opened this issue Apr 22, 2022 · 0 comments

Comments

@Gudahtt
Copy link
Contributor

Gudahtt commented Apr 22, 2022

The TypeScript flag exactOptionalPropertyTypes causes TypeScript to distinguish between object properties that don't exist and properties that are set to undefined. This improves type safety for operations that iterate over keys.

Currently the types in this package result in a compiler error when this flag is enabled. This prevents the use of this flag in projects using this package (e.g. @metamask/controllers).

This flag was added in TypeScript v4.4

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

No branches or pull requests

1 participant