Litestore · Developer docs
Codebase

Linting

Biome formats and lints Litestore's code, with one command to run while you work and another before you push.

Litestore formats and lints its code with Biome. The sections below describe the Biome configuration and which command to run while you work and before you push.

package.json
"dependencies": {
"next": "^16.1.1",
"react": "^19.2.3",
"typescript": "^5.9.3",
"@prisma/client": "7.4.2",
"zod": "^4.3.5",
"better-auth": "^1.4.19",
"inngest": "^3.54.0",
"stripe": "^20.3.1",
"resend": "^6.9.2",
"tailwindcss": "^4.1.18",
}
Biome formats and lints the code, and TypeScript checks the types.

The repository has no ESLint or Prettier configuration. Biome handles both jobs, and its settings are in biome.json. TypeScript checks the types separately through bun run typecheck.

Biome

biome.json uses the 1.9.4 schema, which matches the installed @biomejs/biome (^1.9.4).

biome.json
"formatter": {
  "enabled": true,
  "lineWidth": 100,
  "indentStyle": "space",
  "indentWidth": 2,
  "formatWithErrors": true
},
"javascript": {
  "formatter": {
    "quoteStyle": "double",
    "semicolons": "asNeeded",
    "arrowParentheses": "asNeeded",
    "bracketSpacing": true,
    "trailingCommas": "all"
  }
}

For JavaScript and TypeScript, Biome formats code like this.

SettingWhat Biome doesValue
lineWidthIt wraps lines at this width.100 columns
indentStyle, indentWidthIt indents with spaces.Two spaces
quoteStyleIt writes strings with this quote.Double quotes
semicolonsIt writes semicolons only where they are required.asNeeded
arrowParenthesesIt leaves out parentheses around a single arrow function parameter.asNeeded
trailingCommasIt writes trailing commas everywhere they are allowed.all

Because formatWithErrors is on, Biome still formats a file that doesn't parse, as far as it can.

JSON has its own settings. The parser accepts trailing commas but the formatter never writes them, and the parser rejects comments.

organizeImports is on, so Biome sorts imports and nobody has to keep them in order by hand.

vcs.useIgnoreFile is on with clientKind: "git", so Biome respects .gitignore. files.ignore adds three more paths:

**/.next
**/.source
**/woocommerce-product-feeds/**

Disabled rules

The linter runs Biome's recommended rules with eleven of them turned off.

GroupRules turned off
suspiciousnoExplicitAny, noArrayIndexKey, noConfusingLabels, noShadowRestrictedNames
correctnessuseExhaustiveDependencies
securitynoDangerouslySetInnerHtml
stylenoNonNullAssertion
a11ynoBlankTarget, useAnchorContent, useValidAnchor, useAltText

noDangerouslySetInnerHtml is off because Litestore cleans the HTML it renders with sanitize-html before it reaches the page.

Commands

bun run format

This runs biome format --write .. It only formats the code and doesn't run the linter.

Use lint while you work and verify before you push. GitHub Actions runs verify on every push to main and on every pull request, so running it locally shows the same failures CI would report.

Type checking is separate from Biome and needs extra memory:

package.json
"typecheck": "NODE_OPTIONS='--max-old-space-size=5000' tsc --noEmit"

On a machine with little memory, stop the dev server before you run it.

The repository doesn't install Git hooks, so nothing runs automatically when you commit or push. CI is where verify has to pass.

Quick reference

On this page