microsoft / microsoft/TypeScript

Incremental type checking failure (regression)

Open
#38,354 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Needs Investigation
Dominant language
Go
Stars
111k
Forks
14.3k
Avg merge
2d 4h
Merged PRs (30d)
132

Description

TypeScript Version: 3.7.x-dev.20200505

Search Terms:

Code

  1. clone https://github.com/falsandtru/typed-dom
  2. npm i
  3. open src/builder.ts (no error)
  4. remove the closing parenthesis of API(html, shadow)
  5. redo
  6. error
Argument of type 'Factory<HTMLElementTagNameMap>' is not assignable to parameter of type 'Factory<ShadowHostElementTagNameMap>'.
  Property ''custom-tag'' is missing in type 'HTMLElementTagNameMap' but required in type 'ShadowHostElementTagNameMap'.ts(2345)

Expected behavior:
no error
Actual behavior:

Playground Link:

Related Issues:

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Clone the linked typed-dom reproduction, run npm i, and open src/builder.ts to confirm the initial state. Remove the closing parenthesis from API(html, shadow), redo the check, and investigate the incremental type-checking path until the expected result—no error—is restored.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
compilers
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.