Skip to content

Typescript: Several fixes#952

Merged
alecthomas merged 1 commit intoalecthomas:masterfrom
Gusted:tsx
Apr 2, 2024
Merged

Typescript: Several fixes#952
alecthomas merged 1 commit intoalecthomas:masterfrom
Gusted:tsx

Conversation

@Gusted
Copy link
Copy Markdown
Contributor

@Gusted Gusted commented Apr 1, 2024

Input
ReactDOM.render(
  <p
  // This is a inline comment.
  /*
    This is a
    Multi line comment
  */
  <!-- Another multiline
  comment !-->
  data-test-id="outro" disabled>
	Some text here.
  </p>,
  document.getElementById('root'),
)

Before

Screen Shot 2024-04-02 at 00 39 46

After

Screen Shot 2024-04-02 at 00 39 20

@alecthomas
Copy link
Copy Markdown
Owner

Lovely, thanks.

- Allow comments to be inside of tags.
- Fixes the lexing of `<!--` comments.
- Allow tag names to include `-`.
- Modify module rule to be more strict which is to match `declare module
"Module name"`.
- Added tests.
- Resolves alecthomas#940
- Resolves alecthomas#939
- Resolves alecthomas#801
@Gusted
Copy link
Copy Markdown
Contributor Author

Gusted commented Apr 2, 2024

@alecthomas alecthomas merged commit 736c0ea into alecthomas:master Apr 2, 2024
@Gusted Gusted deleted the tsx branch November 1, 2024 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants