Skip to content

Commit 150e9bc

Browse files
committed
Add plugin config to eslint.
1 parent 7a127b8 commit 150e9bc

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

eslint.config.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import { builtinModules } from "node:module";
1111
const cwd = dirname(fileURLToPath(import.meta.url));
1212
const ezDir = join(cwd, "express-zod-api");
1313
const migrationDir = join(cwd, "migration");
14+
const pluginDir = join(cwd, "zod-plugin");
1415

1516
const importConcerns = [
1617
{
@@ -204,6 +205,18 @@ export default tsPlugin.config(
204205
],
205206
},
206207
},
208+
{
209+
name: "source/plugin",
210+
files: ["zod-plugin/src/*.ts"],
211+
rules: {
212+
"allowed/dependencies": ["error", { packageDir: pluginDir }],
213+
"no-restricted-syntax": [
214+
"warn",
215+
...importConcerns,
216+
...performanceConcerns,
217+
],
218+
},
219+
},
207220
{
208221
name: "source/migration",
209222
files: ["migration/index.ts"],

0 commit comments

Comments
 (0)