Skip to content

🎥 Make videos programmatically with React

disallow zod to be imported unless as type

Jonny Burger9c240daba7d4
diff --git a/packages/cli/.eslintrc b/packages/cli/.eslintrc
index fec15ef0c2..feceda97f2 100644
--- a/packages/cli/.eslintrc
+++ b/packages/cli/.eslintrc
@@ -7,6 +7,18 @@
{
"patterns": ["@remotion/*/src/*"]
}
+ ],
+ "@typescript-eslint/no-restricted-imports": [
+ "error",
+ {
+ "paths": [
+ {
+ "name": "zod",
+ "message": "Can only import zod as a type",
+ "allowTypeImports": true
+ }
+ ]
+ }
]
},
"overrides": [
diff --git a/packages/player/.eslintrc b/packages/player/.eslintrc
index 5c8365c3cc..f9566eea78 100644
--- a/packages/player/.eslintrc
+++ b/packages/player/.eslintrc
@@ -1,4 +1,18 @@
{
"extends": ["@jonny", "plugin:require-extensions/recommended"],
- "plugins": ["require-extensions"]
+ "plugins": ["require-extensions"],
+ "rules": {
+ "@typescript-eslint/no-restricted-imports": [
+ "error",
+ {
+ "paths": [
+ {
+ "name": "zod",
+ "message": "Can only import zod as a type",
+ "allowTypeImports": true
+ }
+ ]
+ }
+ ]
+ }
}