-
Notifications
You must be signed in to change notification settings - Fork 173
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
chore(comments): update comments module to typescript #2513
chore(comments): update comments module to typescript #2513
Conversation
@cdriesler - this looks good to me. I see you have a bunch of notes in the |
@iainsproat multi-region mentioned again today so resurrecting this, TODO's are in order and in line with some style stuff we've decided on since I do think the tests should be moved to ts as well but will catch that in a future PR? cc @alemagio if you'd like to pick this up too |
git mv
etc). The individual commits may be easier to check for specific file changes.Description & motivation
Changes:
To-do before merge:
How doesSmartTextEditorValueSchema
interact with thestring
typing onCommentRecord
? Looks like a later change that .js didn't care about but .ts does? It appears we wantSmartTextEditorValueSchema
in all cases now, but there were just enoughstring
references that I wasn't sure.A few queries were not typed (at the gql level) to provide filter args. I defaulted their values tofalse
because that's what the missing values (often written as(...input.filter || {})
) would resolve toSeveral resolvers did not strictly assert that optional/nullable values existed. I opted for non-null assertions here, even though they're icky, instead of throwing errors. This was to limit changes to business logic.Screenshots:
Validation of changes:
Checklist:
References