@medusajs/eslint-plugin 2.22.4 → 2.22.6
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/AGENTS.md +2 -2
- package/package.json +1 -1
package/AGENTS.md
CHANGED
|
@@ -39,11 +39,11 @@ export default defineConfig([...medusa.configs.recommended])
|
|
|
39
39
|
2. register it in `src/rules/index.ts`
|
|
40
40
|
3. enable it in the right preset block(s) in `src/configs/` with the right `files` scope
|
|
41
41
|
4. add the docs page `www/apps/resources/app/lint/rules/<name>/page.mdx` (the sidebar autogenerates from `lint/rules` in `www/apps/resources/sidebars/tools.mjs`)
|
|
42
|
-
- The monorepo dogfoods the plugin: root
|
|
42
|
+
- The monorepo dogfoods the plugin: root `eslint.config.mjs` imports the built package and `eslint.medusa.mjs` / `yarn lint:medusa` (run in CI) apply only the `@medusajs/*` rules. A new `error` rule can fail CI on existing framework code.
|
|
43
43
|
|
|
44
44
|
## Gotchas
|
|
45
45
|
|
|
46
|
-
- Root
|
|
46
|
+
- Root `eslint.config.mjs` and `www` (`link:../packages/eslint-plugin`) load `dist/`, so run `yarn workspace @medusajs/eslint-plugin build` before linting the repo or www after changing a rule (CI does this explicitly).
|
|
47
47
|
- Keep the plugin registration block free of `files`; scoping it to TS breaks `.js` files with `Could not find plugin "@medusajs"`.
|
|
48
48
|
- Only `strict` may contain rules that need type information; `recommended` and `modules` must stay zero-config.
|
|
49
49
|
- `subscribers/*` and `jobs/*` globs intentionally match direct children only (Medusa only loads those); nested files are utilities.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@medusajs/eslint-plugin",
|
|
3
|
-
"version": "2.22.
|
|
3
|
+
"version": "2.22.6",
|
|
4
4
|
"description": "Official ESLint plugin for Medusa projects. Enforces Medusa's framework conventions across API routes, modules, workflows, subscribers, jobs, admin extensions, and module links.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|