@genesislcap/oxlint-config 14.436.0-FUI-2489.8 → 14.442.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.oxlintrc.json +5 -8
- package/README.md +6 -4
- package/package.json +5 -8
package/.oxlintrc.json
CHANGED
|
@@ -4,9 +4,8 @@
|
|
|
4
4
|
"eslint-plugin-unused-imports",
|
|
5
5
|
{
|
|
6
6
|
"name": "import-es",
|
|
7
|
-
"specifier": "eslint-plugin-import
|
|
8
|
-
}
|
|
9
|
-
"eslint-plugin-perfectionist"
|
|
7
|
+
"specifier": "eslint-plugin-import"
|
|
8
|
+
}
|
|
10
9
|
],
|
|
11
10
|
"env": {
|
|
12
11
|
"builtin": true,
|
|
@@ -80,13 +79,11 @@
|
|
|
80
79
|
"import-es/no-duplicates": "warn",
|
|
81
80
|
"import-es/no-self-import": "error",
|
|
82
81
|
"import-es/no-useless-path-segments": "warn",
|
|
83
|
-
"import-es/order":
|
|
84
|
-
"perfectionist/sort-imports": [
|
|
82
|
+
"import-es/order": [
|
|
85
83
|
"warn",
|
|
86
84
|
{
|
|
87
|
-
"
|
|
88
|
-
"order": "asc",
|
|
89
|
-
"newlinesBetween": 0
|
|
85
|
+
"groups": ["builtin", "external", "internal", "parent", "sibling", "index"],
|
|
86
|
+
"alphabetize": { "order": "asc", "caseInsensitive": true }
|
|
90
87
|
}
|
|
91
88
|
],
|
|
92
89
|
"no-magic-numbers": [
|
package/README.md
CHANGED
|
@@ -6,17 +6,19 @@ Published **Oxlint** rules for Genesis Foundation UI. It is the lint analogue of
|
|
|
6
6
|
|
|
7
7
|
- Ships **[`.oxlintrc.json`](./.oxlintrc.json)** — the only file you should edit for Oxlint rule changes in this product line.
|
|
8
8
|
- Keeps rule **intent** aligned with `@genesislcap/eslint-config` and the monorepo root [`eslint.config.mjs`](../../../../eslint.config.mjs) (ESLint-only overrides stay in ESLint).
|
|
9
|
-
- **Does not format code.** Formatting is **Oxfmt**
|
|
9
|
+
- **Does not format code.** Formatting is **Oxfmt** — config lives in the root **`.oxfmtrc.json`** (copy it to your app, no extra package needed).
|
|
10
10
|
|
|
11
11
|
## How it runs in the monorepo
|
|
12
12
|
|
|
13
|
-
1. **`npm run lint`** / **`genx lint`** runs **Oxlint** (first, before Oxfmt and Stylelint) from the **current working directory**.
|
|
13
|
+
1. **`npm run lint:ox`** / **`genx lint -l ox`** runs **Oxlint** (first, before Oxfmt and Stylelint) from the **current working directory**. The default `genx lint` still runs the legacy ESLint pipeline for backward compatibility.
|
|
14
14
|
2. The repo root has a small [`.oxlintrc.json`](../../../../.oxlintrc.json) that **only** `extends` this package so `oxlint` finds the same rules from the workspace root.
|
|
15
|
-
3. Nested apps that run `genx lint` from their own folder may need a local stub `extends` (see Consumption) so config resolves correctly.
|
|
15
|
+
3. Nested apps that run `genx lint -l ox` from their own folder may need a local stub `extends` (see Consumption) so config resolves correctly.
|
|
16
16
|
|
|
17
17
|
## Import rules and ESLint
|
|
18
18
|
|
|
19
|
-
Oxlint loads
|
|
19
|
+
Oxlint loads **`eslint-plugin-import`** as a **[JS plugin](https://oxc.rs/docs/guide/usage/linter/js-plugins.html)** under the alias **`import-es`** (avoids clashing with Oxlint’s built-in `import` plugin). In this config, `import-es` covers **`newline-after-import`**, **`no-self-import`**, **`no-useless-path-segments`** (warn), and **`no-duplicates`** (warn).
|
|
20
|
+
|
|
21
|
+
**Import ordering** is handled by **`import-es/order`** with the same groups and `alphabetize` config as `@genesislcap/eslint-config`, so both linters enforce identical ordering. `import-es/first` is disabled (redundant with `import-es/order`).
|
|
20
22
|
|
|
21
23
|
**`import/no-extraneous-dependencies`** is intentionally **not** run in Oxlint here (noisy with per-package `package.json` in a large monorepo). Use **ESLint** for that.
|
|
22
24
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@genesislcap/oxlint-config",
|
|
3
3
|
"description": "Oxlint rules derived from @genesislcap/eslint-config and eslint.config.mjs",
|
|
4
|
-
"version": "14.
|
|
4
|
+
"version": "14.442.0",
|
|
5
5
|
"license": "SEE LICENSE IN license.txt",
|
|
6
6
|
"engines": {
|
|
7
7
|
"node": ">=22.0.0"
|
|
@@ -14,8 +14,7 @@
|
|
|
14
14
|
],
|
|
15
15
|
"peerDependencies": {
|
|
16
16
|
"eslint-import-resolver-typescript": "^3.5.5",
|
|
17
|
-
"eslint-plugin-import
|
|
18
|
-
"eslint-plugin-perfectionist": "^5.0.0",
|
|
17
|
+
"eslint-plugin-import": "^2.27.5",
|
|
19
18
|
"eslint-plugin-unused-imports": "^4.0.0",
|
|
20
19
|
"oxlint": ">=1.59.0"
|
|
21
20
|
},
|
|
@@ -28,10 +27,8 @@
|
|
|
28
27
|
"access": "public"
|
|
29
28
|
},
|
|
30
29
|
"scripts": {
|
|
31
|
-
"lint": "genx lint",
|
|
32
|
-
"lint:fix": "genx lint --fix"
|
|
33
|
-
"lint:ox": "genx lint -l ox",
|
|
34
|
-
"lint:ox:fix": "genx lint -l ox --fix"
|
|
30
|
+
"lint": "genx lint -l ox",
|
|
31
|
+
"lint:fix": "genx lint -l ox --fix"
|
|
35
32
|
},
|
|
36
|
-
"gitHead": "
|
|
33
|
+
"gitHead": "ad425e4ea17dad7d5b580200f2ca31758896d07f"
|
|
37
34
|
}
|