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

Stricter typescript rules #161

Open
lucca-fonte opened this issue Jul 4, 2020 · 7 comments
Open

Stricter typescript rules #161

lucca-fonte opened this issue Jul 4, 2020 · 7 comments

Comments

@lucca-fonte
Copy link
Contributor

I saw in #1 v1 Roadmap section that the Stricter typescript rules is available. If no one is working on it I'm interested in tackling this 😃. @wovalle can you elaborate about this issue?

@wovalle
Copy link
Owner

wovalle commented Jul 4, 2020

Hey, thanks for the interest!

I haven't digged too much into it but my idea was to try to remove as much rules as I can from the tsconfig file. Ideally be able to run fireorm with strict: true but it wouldn't be entirely possible

@lucca-fonte
Copy link
Contributor Author

Ok. I will play around with the strict rule family and see what we can do.

@lucca-fonte
Copy link
Contributor Author

Working on the strict migration I realized how much of a daunting task that is 😅. Do you guys think it would be possible to take an incremental approach to this migration, something similar to this comment?

@wovalle
Copy link
Owner

wovalle commented Jul 12, 2020

That sounds good! I'm working in a PR that will get rid a lot of errors, might be a good idea working after I'm done with it 😅
#165

@wovalle
Copy link
Owner

wovalle commented Jul 18, 2020

Update: merged #165

@lucca-fonte
Copy link
Contributor Author

Addressing this comment. I'm thinking of doing on a folder-by-folder manner. With that in mind, here is the work pending:

  • src/Batch/
  • src/Errors/
  • src/Transaction/
  • src/AbstractFirestoreRepository.ts
  • src/BaseFirestoreRepository.ts
  • src/BaseRepository.ts
  • src/helpers.ts
  • src/MetadataStorage.ts
  • src/QueryBuilder.ts
  • src/utils.ts

To make a folder or file strict we just need to add it to the include cause in the inner tsconfing.json and fix the errors. After all the files are migrated we can remove the inner tsconfig and add the strict option to the outer tsconfig

@lucca-fonte
Copy link
Contributor Author

Will work on the Batch migration now 😄

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

2 participants