Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Support for JSON commentsΒ #83

@brettz9

Description

@brettz9

Summary

Support a JSON with comments mode so that users can opt not to get errors when comments are used within JSON files (or ideally, within specific JSON file names, like .eslintrc and .eslintrc.json).

Motivation

It is annoying to see linting errors when viewing such a file, and it deters one from adding helpful comments to ESLint RC files (ESLint config files support this format: https://eslint.org/docs/user-guide/configuring/configuration-files#comments-in-configuration-files ).

Describe alternatives you've considered

The existing language-json-comments package does not work for me.

While I understand JSON proper does not support comments, I think it makes sense for this existing package to implement since it appears that often the "json" extension is still used and Visual Studio treats this similarly as another mode

Additional context

There is a spec for this and several parsers:

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