Skip to content

Available Rules

The --fix option on the command line automatically fixes problems reported by rules which have a wrench 🔧 below.
The rules with the following star ⭐ are included in the plugin:jsonc/recommended config.

JSONC Rules

Rule IDDescriptionFixableJSONJSONCJSON5
jsonc/autoapply jsonc rules similar to your configured ESLint core rules🔧
jsonc/key-name-casingenforce naming convention to property key names
jsonc/no-bigint-literalsdisallow BigInt literals
jsonc/no-binary-expressiondisallow binary expression🔧
jsonc/no-binary-numeric-literalsdisallow binary numeric literals🔧
jsonc/no-commentsdisallow comments
jsonc/no-escape-sequence-in-identifierdisallow escape sequences in identifiers.🔧
jsonc/no-hexadecimal-numeric-literalsdisallow hexadecimal numeric literals🔧
jsonc/no-infinitydisallow Infinity
jsonc/no-nandisallow NaN
jsonc/no-number-propsdisallow number property keys🔧
jsonc/no-numeric-separatorsdisallow numeric separators🔧
jsonc/no-octal-numeric-literalsdisallow octal numeric literals🔧
jsonc/no-parenthesizeddisallow parentheses around the expression🔧
jsonc/no-plus-signdisallow plus sign🔧
jsonc/no-regexp-literalsdisallow RegExp literals
jsonc/no-template-literalsdisallow template literals🔧
jsonc/no-undefined-valuedisallow undefined
jsonc/no-unicode-codepoint-escapesdisallow Unicode code point escape sequences.🔧
jsonc/sort-array-valuesrequire array values to be sorted🔧
jsonc/sort-keysrequire object keys to be sorted🔧
jsonc/valid-json-numberdisallow invalid number for JSON🔧
jsonc/vue-custom-block/no-parsing-errordisallow parsing errors in Vue custom blocks

Extension Rules

Rule IDDescriptionFixableJSONJSONCJSON5
jsonc/array-bracket-newlineenforce line breaks after opening and before closing array brackets🔧
jsonc/array-bracket-spacingdisallow or enforce spaces inside of brackets🔧
jsonc/array-element-newlineenforce line breaks between array elements🔧
jsonc/comma-danglerequire or disallow trailing commas🔧
jsonc/comma-styleenforce consistent comma style🔧
jsonc/indentenforce consistent indentation🔧
jsonc/key-spacingenforce consistent spacing between keys and values in object literal properties🔧
jsonc/no-dupe-keysdisallow duplicate keys in object literals
jsonc/no-floating-decimaldisallow leading or trailing decimal points in numeric literals🔧
jsonc/no-irregular-whitespacedisallow irregular whitespace
jsonc/no-multi-strdisallow multiline strings
jsonc/no-octal-escapedisallow octal escape sequences in string literals
jsonc/no-octaldisallow legacy octal literals
jsonc/no-sparse-arraysdisallow sparse arrays
jsonc/no-useless-escapedisallow unnecessary escape usage
jsonc/object-curly-newlineenforce consistent line breaks inside braces🔧
jsonc/object-curly-spacingenforce consistent spacing inside braces🔧
jsonc/object-property-newlineenforce placing object properties on separate lines🔧
jsonc/quote-propsrequire quotes around object literal property names🔧
jsonc/quotesenforce use of double or single quotes🔧
jsonc/space-unary-opsdisallow spaces after unary operators🔧