superlint/.github/linters/.eslintrc.yml
Lukas Gravley 3e0bd7fff4
Eslint for json jsonc and json5 (#1524)
* adding it

* fix typo

* fix tests

* adding back jsonlint

* adding back jsonlint

* fix spacing

* found the typo

* add tests

* adding rules for json

* add to local
2021-05-11 10:54:58 -05:00

73 lines
1.1 KiB
YAML

---
#############################
#############################
## JavaScript Linter rules ##
#############################
#############################
############
# Env Vars #
############
env:
browser: true
es6: true
jest: true
###############
# Global Vars #
###############
globals:
Atomics: readonly
SharedArrayBuffer: readonly
###############
# Parser vars #
###############
parser: '@typescript-eslint/parser'
parserOptions:
ecmaVersion: 2018
sourceType: module
###########
# Plugins #
###########
plugins:
- '@typescript-eslint'
#########
# Rules #
#########
rules: {}
##############################
# Overrides for JSON parsing #
##############################
overrides:
# JSON files
- files:
- "*.json"
extends:
- plugin:jsonc/recommended-with-json
parser: jsonc-eslint-parser
parserOptions:
jsonSyntax: JSON
# JSONC files
- files:
- "*.jsonc"
extends:
- plugin:jsonc/recommended-with-jsonc
parser: jsonc-eslint-parser
parserOptions:
jsonSyntax: JSONC
# JSON5 files
- files:
- "*.json5"
extends:
- plugin:jsonc/recommended-with-json5
parser: jsonc-eslint-parser
parserOptions:
jsonSyntax: JSON5