feat: Introduce biome (#25664)
* Configure biome * Fix companion build * fix: remove generated files from formatter ignore list to enable proper formatting Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * fix: add explicit stripe dependency to @calcom/features to fix type resolution Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * fix: rename const require to nodeRequire in generate-swagger.ts to avoid TypeScript reserved identifier conflict Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * fix: add guard for document in makeBodyVisible to prevent test environment teardown errors Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * fix: replace ESLint with Biome CLI in embed-code-generator.e2e.ts Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * fix: address cubic review comments - Fix invalid --reporter-path Biome CLI option by using shell redirection - Fix packages/lib lint report filename (app-store.json -> lib.json) - Add typescript-eslint and eslint back to companion for lint:react-compiler - Add missing restricted import rules to biome.json: - packages/lib: add ../trpc/** and @trpc/server restrictions - packages/trpc: add ../apps/web/** restriction Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * chore: regenerate companion bun.lock after adding eslint dependencies Co-Authored-By: Volnei Munhoz <volnei.munhoz@gmail.com> * Remove remaining eslint things * add tailwind directives --------- Co-authored-by: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
co-authored by
Volnei Munhoz
Devin AI
parent
96dc3b5cc6
commit
7c373ddad6
@@ -1,8 +1,10 @@
|
||||
const skipWarnings = ["1", "true", "yes", "on"].includes((process.env.SKIP_WARNINGS ?? "").toLowerCase());
|
||||
|
||||
export default {
|
||||
"(apps|packages)/**/*.{js,ts,jsx,tsx}": (files) =>
|
||||
process.env.SKIP_WARNINGS === "1"
|
||||
? `eslint --fix --flag v10_config_lookup_from_file ${files.join(" ")}`
|
||||
: `eslint --fix --flag v10_config_lookup_from_file --max-warnings=0 ${files.join(" ")}`,
|
||||
"*.json": ["prettier --write"],
|
||||
"(apps|packages|companion)/**/*.{js,ts,jsx,tsx}": (files) =>
|
||||
skipWarnings
|
||||
? `biome lint --write ${files.join(" ")}`
|
||||
: `biome lint --write --error-on-warnings ${files.join(" ")}`,
|
||||
"*.json": (files) => `biome format --write ${files.join(" ")}`,
|
||||
"packages/prisma/schema.prisma": ["prisma format"],
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user