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

Use --strictNullChecks for safer code base #403

Open
harunurhan opened this issue Sep 25, 2017 · 0 comments
Open

Use --strictNullChecks for safer code base #403

harunurhan opened this issue Sep 25, 2017 · 0 comments

Comments

@harunurhan
Copy link
Contributor

In the release notes of v2 you can read about the feature. It is enforces for null/undefined checks where it's possible to have based on the variable types.

There is also ! operator, when you're sure that a variable is non-null, to be used where compiler couldn't guess. For example: As far as I checked this kinda happens a lot with our current JSONSchema which has all possible things optional inside and not strict enough so before we have to change it as well.

http://www.typescriptlang.org/docs/handbook/release-notes/typescript-2-0.html

In the future, or even maybe with this one we can also enable other strict rules, such as --noImplicitAny and --noImplicitThis.

@harunurhan harunurhan assigned harunurhan and unassigned harunurhan Sep 25, 2017
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