1 # @medusajs/eslint-plugin
2
3 Official ESLint plugin for Medusa projects. Codifies Medusa's framework conventions into automatically-enforced static checks across API routes, modules, workflows, subscribers, scheduled jobs, admin extensions, and module links.
4
5 > Status: pre-release. The plugin currently ships with no rules — only the package scaffold and `recommended` / `strict` config shapes. Rules will land incrementally; see `MEDUSA_LINT_RULES_CATALOG.md` at the repo root for the planned set.
6
7 ## Installation
8
9 ```bash
10 npm install -D @medusajs/eslint-plugin eslint
11 ```
12
13 `eslint` is a peer dependency — install it in the consuming project.
14
15 ## Usage (flat config)
16
17 ```js
18 // eslint.config.js
19 import medusa from "@medusajs/eslint-plugin"
20
21 export default [...medusa.configs.recommended]
22 ```
23
24 ## Configs
25
26 - `recommended` — default preset for Medusa projects.
27 - `strict` — extends `recommended` and enables stricter, opt-in heuristics.
28
29 ## Development
30
31 ```bash
32 yarn workspace @medusajs/eslint-plugin build
33 yarn workspace @medusajs/eslint-plugin test
34 ```