Skip to content

TypeScript tsconfig unable to parse comments #4555

@risingBirdSong

Description

@risingBirdSong

🐛 bug report

Description of the problem

import a project from my github (great feature!) that has a tsconfig complete with comments. But it looks like coding sandbox can't parse the comments.

Error -> We weren't able to parse: '/tsconfig.json': Parse error on line 2:
...erOptions": { /* Basic Options */
----------------------^
Expecting 'STRING', '}', got 'undefined'

How has this issue affected you? What are you trying to accomplish?

would like to be able to keep the comments, they're useful and are part of my repo. Fixing this will making importing from github repo more seamless.

Link to sandbox: link (optional)

(not the original repo but a simplified one only to demonstrate the problem)
https://codesandbox.io/s/fragrant-darkness-8zu6f?file=/tsconfig.json

Your Environment

| Software | Name/Version |
Windows 10 Home Version 2004 Build 19041
| Browser |
Same error in Microsoft Edge and Google Chrome

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions