biome-config-expo
v0.1.1
Published
Base Biome config for Expo projects. Supports JSX, TypeScript, React Native globals, and platform-specific file extensions.
Maintainers
Readme
biome-config-expo
Shareable Biome config for Expo projects. A Biome equivalent of eslint-config-expo.
Includes React Native globals, JSX automatic runtime, React Hooks rules, and sensible defaults for TypeScript — so you don't have to configure them yourself.
Install
npm install -D biome-config-expo @biomejs/biomeUsage
Create a biome.json in your project root:
{
"$schema": "https://biomejs.dev/schemas/2.4.4/schema.json",
"extends": ["biome-config-expo/biome.json"]
}Override anything you need:
{
"$schema": "https://biomejs.dev/schemas/2.4.4/schema.json",
"extends": ["biome-config-expo/biome.json"],
"formatter": {
"lineWidth": 120
}
}What's Included
Globals — __DEV__, fetch, FormData, XMLHttpRequest, requestAnimationFrame, alert, navigator, window, process, and others from the React Native environment. Config files (*.config.js, metro.config.*) also get Node.js globals.
Linter — All Biome recommended rules, plus rules mapped from eslint-config-expo:
- React Hooks:
useExhaustiveDependencies,useHookAtTopLevel - Correctness:
noUnusedVariables,noUnusedImports,useIsNan,useJsxKeyInIterable - Suspicious:
noDoubleEquals,noDuplicateObjectKeys,noDuplicateJsxProps,noVar - Style:
useConst,useConsistentArrayType,useImportType - Complexity:
noUselessConstructor,useOptionalChain
Formatter — 2-space indentation, 100 character line width, Biome defaults for everything else.
JSX Runtime — Set to transparent (React 17+ automatic transform), matching Expo's default.
License
MIT
