Skip to content

Conversation

@DayuanJiang
Copy link
Owner

Summary

  • Added Biome configuration for code formatting and linting
  • Configured VSCode settings for auto-format on save
  • Added Husky pre-commit hook for Biome checks
  • Fixed TypeScript types in chat/route.ts using AI SDK type guards (isTextUIPart, isFileUIPart)
  • Added type="button" attributes for accessibility
  • Configured balanced lint rules (warn for non-critical issues, disabled rules that conflict with project conventions)

Biome Configuration

Rules configured in biome.json:

  • noExplicitAny: warn (allow but track for future improvement)
  • noArrayIndexKey: off (common React pattern)
  • noStaticElementInteractions: off (acceptable for this project)
  • useKeyWithClickEvents: off (acceptable for this project)
  • useExhaustiveDependencies: warn (helpful but not blocking)

Test Plan

  • npx @biomejs/biome check passes
  • TypeScript compilation succeeds
  • Dev server runs without errors
  • All routes work correctly

- Add Biome as formatter and linter (replaces Prettier)
- Configure Husky + lint-staged for pre-commit hooks
- Add VS Code settings for format on save
- Ignore components/ui/ (shadcn generated code)
- Remove semicolons, use 4-space indent
- Reformat all files to new style
@vercel
Copy link

vercel bot commented Dec 6, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
next-ai-draw-io Ready Ready Preview Comment Dec 6, 2025 3:45am

@DayuanJiang DayuanJiang merged commit 150eb1f into main Dec 6, 2025
4 checks passed
@DayuanJiang DayuanJiang deleted the feat/biome-setup branch December 6, 2025 03:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants