microsoft / microsoft/TypeScript-TmLanguage
@nhardy optional chaining is supported. If you have a sample that doesnt work please open another issue with it to track it separately.
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 471
- Forks
- 149
- PR merge metrics
- No merged PRs in 30d
Description
Originally posted by @sheetalkamat in https://github.com/microsoft/TypeScript-TmLanguage/issues/522#issuecomment-549491582
@nhardy optional chaining is supported. If you have a sample that doesnt work please open another issue with it to track it separately.
Turns out optional chain doesn't work. 🙂
declare let foo: Foo | undefined;
foo && foo.bar && foo.bar.baz;
interface Foo {
bar?: {
baz?: string;
}
}

Contributor guide
No contributing guide indexed for this repository
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 reproducing the TypeScript sample in the repository's TextMate grammar and inspect the rules responsible for optional chaining and nested property access. Compare the syntax highlighting with the expected treatment of the sample; done means optional-chain expressions are recognized correctly across the supported editor grammars.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100