rust-lang / rust-lang/rust-analyzer
editor/code: Enable TypeScript's `--exactOptionalPropertyTypes`
Open
Nobody has claimed this yet.
A-vscode
C-enhancement
- Dominant language
- Rust
- Stars
- 16.9k
- Forks
- 2.2k
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 72
Description
This issue proposes to enable TS' --exactOptionalPropertyTypes option.
To enable this option,
npm:@types/vscodechages their optional property types to acceptundefined(e.g.bar?: Fooshould bebar?: Foo | undefinedif there is no problem).- Or we need to change our code to avoid to assign
undefinedto properties as marked as optional.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the editor/code TypeScript configuration and the code that assigns undefined to optional properties. Check the linked TypeScript option and the @types/vscode examples in the issue, then determine whether enabling the option requires updated dependency types or code changes; done means the option is enabled without type errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100