@geoql/oxlint-plugin-nuxt-doctor 0.0.0-bootstrap → 0.1.1
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/LICENSE +21 -0
- package/README.md +25 -16
- package/package.json +10 -10
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Vinayak Kulkarni
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,28 +1,37 @@
|
|
|
1
1
|
# `@geoql/oxlint-plugin-nuxt-doctor`
|
|
2
2
|
|
|
3
|
-
> oxlint JS plugin
|
|
3
|
+
> oxlint JS plugin holding the Nuxt 4 script-level rules that [`@geoql/doctor-core`](../doctor-core) runs.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
This package is a rule pack, not a tool. It's the Nuxt half of the script pass: oxlint JS-plugin rules that fire against the `<script>` / `<script setup>` ESTree oxlint extracts from `.vue` files and server handlers. `doctor-core` generates the `.oxlintrc.json` that loads this plugin alongside `@geoql/oxlint-plugin-vue-doctor` and wires it in automatically, so **you don't install or configure it directly**. Run [`@geoql/nuxt-doctor`](../nuxt-doctor) and these rules come along for free.
|
|
6
6
|
|
|
7
|
-
##
|
|
7
|
+
## What's in here
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
9
|
+
Script-level Nuxt rules across four categories. Other Nuxt checks (`structure`, `nitro`, `seo`, `cloudflare`, `modules-deps`, plus cross-file `data-fetching`) run inside `doctor-core` because they need project-level or multi-file context rather than a single script AST.
|
|
10
|
+
|
|
11
|
+
| Category | Rules |
|
|
12
|
+
| --------------- | --------------------------------------------------------------------------------------------------------------------- |
|
|
13
|
+
| `ai-slop` | `useState` for server data, fetch in setup, `process.client`/`process.server`, explicit imports of auto-imported APIs |
|
|
14
|
+
| `hydration` | `clientOnly` for browser APIs, no `document` in setup |
|
|
15
|
+
| `server-routes` | typed `defineEventHandler`, `createError` on failure, validate body with h3 v2 |
|
|
16
|
+
| `data-fetching` | required `useAsyncData` key inside loops |
|
|
17
|
+
|
|
18
|
+
`nuxt-doctor` surfaces these Nuxt rules **on top of** the full Vue rule set, so a Nuxt audit checks both. To see every rule with its id, severity, and preset membership, run `nuxt-doctor list-rules` (or filter, e.g. `nuxt-doctor list-rules --category hydration`).
|
|
19
|
+
|
|
20
|
+
## Install
|
|
21
|
+
|
|
22
|
+
```sh
|
|
23
|
+
npm i @geoql/oxlint-plugin-nuxt-doctor
|
|
18
24
|
```
|
|
19
25
|
|
|
20
|
-
|
|
26
|
+
Published on [npm](https://www.npmjs.com/package/@geoql/oxlint-plugin-nuxt-doctor) and [JSR](https://jsr.io/@geoql/oxlint-plugin-nuxt-doctor) at `v0.1.0` with provenance. ESM-only, TypeScript. `oxlint` is a peer dependency. Most people never add this dependency themselves; `doctor-core` resolves it for you.
|
|
27
|
+
|
|
28
|
+
## Scope
|
|
29
|
+
|
|
30
|
+
Nuxt 4 only (the `app/` directory layout with `compatibilityVersion: 4`). Severity levels are `error | warn | info`.
|
|
21
31
|
|
|
22
|
-
|
|
23
|
-
| ---- | -------- | -------- |
|
|
32
|
+
## Architecture
|
|
24
33
|
|
|
25
|
-
|
|
34
|
+
See [`docs/ARCHITECTURE.md`](../../docs/ARCHITECTURE.md) for how the JS plugin co-loads with oxlint's native `vue` plugin and why script, template, and cross-file rules live in different passes.
|
|
26
35
|
|
|
27
36
|
## License
|
|
28
37
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@geoql/oxlint-plugin-nuxt-doctor",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "oxlint JS plugin for Nuxt 4 anti-patterns and AI-slop detection. Pairs with oxlint's built-in vue plugin via jsPlugins. TypeScript, ESM.",
|
|
6
6
|
"keywords": [
|
|
@@ -41,14 +41,6 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"scripts": {
|
|
45
|
-
"lint": "vp lint src",
|
|
46
|
-
"lint:fix": "vp lint src --fix",
|
|
47
|
-
"format": "vp fmt",
|
|
48
|
-
"format:check": "vp fmt --check",
|
|
49
|
-
"build": "vp pack",
|
|
50
|
-
"test": "vitest run"
|
|
51
|
-
},
|
|
52
44
|
"devDependencies": {
|
|
53
45
|
"@types/node": "^25.9.1",
|
|
54
46
|
"oxc-parser": "0.133.0",
|
|
@@ -57,5 +49,13 @@
|
|
|
57
49
|
},
|
|
58
50
|
"peerDependencies": {
|
|
59
51
|
"oxlint": "^1.66.0"
|
|
52
|
+
},
|
|
53
|
+
"scripts": {
|
|
54
|
+
"lint": "vp lint src",
|
|
55
|
+
"lint:fix": "vp lint src --fix",
|
|
56
|
+
"format": "vp fmt",
|
|
57
|
+
"format:check": "vp fmt --check",
|
|
58
|
+
"build": "vp pack",
|
|
59
|
+
"test": "vitest run"
|
|
60
60
|
}
|
|
61
|
-
}
|
|
61
|
+
}
|