mirror of
https://github.com/danbulant/oxc
synced 2026-05-24 12:21:58 +00:00
parent
46e5360372
commit
4551baaf4a
3 changed files with 19 additions and 3 deletions
|
|
@ -51,7 +51,23 @@ use crate::{options::LintPlugins, utils::read_to_string};
|
||||||
pub struct Oxlintrc {
|
pub struct Oxlintrc {
|
||||||
pub plugins: LintPlugins,
|
pub plugins: LintPlugins,
|
||||||
pub categories: OxlintCategories,
|
pub categories: OxlintCategories,
|
||||||
/// See [Oxlint Rules](https://oxc.rs/docs/guide/usage/linter/rules.html).
|
/// Example
|
||||||
|
///
|
||||||
|
/// `.oxlintrc.json`
|
||||||
|
///
|
||||||
|
/// ```json
|
||||||
|
/// {
|
||||||
|
/// "$schema": "./node_modules/oxlint/configuration_schema.json",
|
||||||
|
/// "rules": {
|
||||||
|
/// "eqeqeq": "warn",
|
||||||
|
/// "import/no-cycle": "error",
|
||||||
|
/// "prefer-const": ["error", { "ignoreReadBeforeAssign": true }]
|
||||||
|
/// }
|
||||||
|
/// }
|
||||||
|
/// ```
|
||||||
|
///
|
||||||
|
/// See [Oxlint Rules](https://oxc.rs/docs/guide/usage/linter/rules.html) for the list of
|
||||||
|
/// rules.
|
||||||
pub rules: OxlintRules,
|
pub rules: OxlintRules,
|
||||||
pub settings: OxlintSettings,
|
pub settings: OxlintSettings,
|
||||||
/// Environments enable and disable collections of global variables.
|
/// Environments enable and disable collections of global variables.
|
||||||
|
|
|
||||||
|
|
@ -50,7 +50,7 @@ expression: json
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"rules": {
|
"rules": {
|
||||||
"description": "See [Oxlint Rules](https://oxc.rs/docs/guide/usage/linter/rules.html).",
|
"description": "Example\n\n`.oxlintrc.json`\n\n```json { \"$schema\": \"./node_modules/oxlint/configuration_schema.json\", \"rules\": { \"eqeqeq\": \"warn\", \"import/no-cycle\": \"error\", \"prefer-const\": [\"error\", { \"ignoreReadBeforeAssign\": true }] } } ```\n\nSee [Oxlint Rules](https://oxc.rs/docs/guide/usage/linter/rules.html) for the list of rules.",
|
||||||
"default": {},
|
"default": {},
|
||||||
"allOf": [
|
"allOf": [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -46,7 +46,7 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"rules": {
|
"rules": {
|
||||||
"description": "See [Oxlint Rules](https://oxc.rs/docs/guide/usage/linter/rules.html).",
|
"description": "Example\n\n`.oxlintrc.json`\n\n```json { \"$schema\": \"./node_modules/oxlint/configuration_schema.json\", \"rules\": { \"eqeqeq\": \"warn\", \"import/no-cycle\": \"error\", \"prefer-const\": [\"error\", { \"ignoreReadBeforeAssign\": true }] } } ```\n\nSee [Oxlint Rules](https://oxc.rs/docs/guide/usage/linter/rules.html) for the list of rules.",
|
||||||
"default": {},
|
"default": {},
|
||||||
"allOf": [
|
"allOf": [
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue