-
Notifications
You must be signed in to change notification settings - Fork 45
Add linter documentation #59
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 1 commit
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
455af2a
Add linter documentation
hasit ba319c5
docs: Move linter documentation to tools folder
hasit 1d04172
Add more tools
hasit 191e19e
Add LanguageTool documentation and configuration
hasit 2303cd0
Update Biome documentation and configuration
hasit 78159d2
docs: Update linter documentation and configuration
hasit 0b59424
chore: Update tools category label in _category_.yml
hasit 0fda09b
chore: Update tools category label and add new tools
hasit 27c6bb1
docs: Fix typo in Biome linter documentation
hasit 23acf22
chore: Add SwiftLint documentation and configuration
hasit ba5b505
Add golangci-lint, PHPStan, and SwiftLint documentation and configura…
hasit 9d01dfe
Add Yamllint documentation and configuration
hasit 9276d99
Add Checkov and Gitleaks documentation and configuration
hasit File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Update Biome documentation and configuration
- Loading branch information
commit 2303cd089b1399d2e9913978c499d8bcdf29b67b
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,198 @@ | ||
--- | ||
title: Biome | ||
sidebar_label: Biome | ||
description: CodeRabbit's guide to Biome. | ||
sidebar_position: 5 | ||
--- | ||
|
||
[Biome](https://biomejs.dev/) is linter for JavaScript, TypeScript, JSX, TSX, JSON, JSONC, CSS files. | ||
|
||
## Files | ||
|
||
Biome will run on files with the following extensions: | ||
|
||
- `.js` | ||
- `.ts` | ||
- `.cjs` | ||
- `.mjs` | ||
- `.d.cts` | ||
- `.d.mts` | ||
- `.jsx` | ||
- `.tsx` | ||
- `.json` | ||
- `.jsonc` | ||
- `.css` | ||
|
||
## Configuration | ||
|
||
Biome supports the following config files: | ||
|
||
- `biome.jsonc` | ||
- `biome.json` | ||
|
||
CodeRabbit will use the following settings based on the profile selected if no config file is found: | ||
|
||
### Chill | ||
|
||
```json | ||
{ | ||
"$schema": "https://biomejs.dev/schemas/1.8.3/schema.json", | ||
"organizeImports": { | ||
"enabled": false | ||
}, | ||
"formatter": { | ||
"enabled": false | ||
}, | ||
"linter": { | ||
"enabled": true, | ||
"rules": { | ||
"all": false, | ||
"recommended": true, | ||
"a11y": { | ||
"recommended": false | ||
}, | ||
"correctness": { | ||
"useExhaustiveDependencies": "off", | ||
"noInnerDeclarations": "off" | ||
}, | ||
"style": { | ||
"recommended": false, | ||
"noArguments": "warn", | ||
"noCommaOperator": "warn", | ||
"noUselessElse": "warn", | ||
"useAsConstAssertion": "off", | ||
"useBlockStatements": "off", | ||
"useConsistentArrayType": "off", | ||
"useDefaultParameterLast": "warn", | ||
"useEnumInitializers": "off", | ||
"useExponentiationOperator": "warn", | ||
"useExportType": "off", | ||
"useFragmentSyntax": "off", | ||
"useImportType": "off", | ||
"useLiteralEnumMembers": "warn", | ||
"useShorthandArrayType": "off", | ||
"noUnusedTemplateLiteral": "off" | ||
}, | ||
"complexity": { | ||
"noForEach": "off", | ||
"noExcessiveCognitiveComplexity": { | ||
"level": "off", | ||
"options": { | ||
"maxAllowedComplexity": 25 | ||
} | ||
}, | ||
"useLiteralKeys": "off", | ||
"useArrowFunction": "off", | ||
"useFlatMap": "off" | ||
}, | ||
"suspicious": { | ||
"noArrayIndexKey": "off", | ||
"noExplicitAny": "off", | ||
"noImplicitAnyLet": "off", | ||
"noDoubleEquals": "off" | ||
}, | ||
"nursery": { | ||
"all": false | ||
} | ||
} | ||
}, | ||
"css": { | ||
"linter": { | ||
"enabled": true | ||
}, | ||
"parser": { | ||
"cssModules": true | ||
} | ||
}, | ||
"javascript": { | ||
"parser": { | ||
"unsafeParameterDecoratorsEnabled": true | ||
} | ||
} | ||
} | ||
``` | ||
|
||
### Assertive | ||
|
||
```json | ||
{ | ||
"$schema": "https://biomejs.dev/schemas/1.8.3/schema.json", | ||
"organizeImports": { | ||
"enabled": false | ||
}, | ||
"formatter": { | ||
"enabled": false | ||
}, | ||
"linter": { | ||
"enabled": true, | ||
"rules": { | ||
"all": false, | ||
"recommended": true, | ||
"a11y": { | ||
"recommended": "" | ||
}, | ||
"correctness": { | ||
"useExhaustiveDependencies": "off", | ||
"noInnerDeclarations": "warn" | ||
}, | ||
"style": { | ||
"recommended": true, | ||
"noArguments": "warn", | ||
"noCommaOperator": "warn", | ||
"noUselessElse": "warn", | ||
"useAsConstAssertion": "off", | ||
"useBlockStatements": "off", | ||
"useConsistentArrayType": "off", | ||
"useDefaultParameterLast": "warn", | ||
"useEnumInitializers": "off", | ||
"useExponentiationOperator": "warn", | ||
"useExportType": "off", | ||
"useFragmentSyntax": "off", | ||
"useImportType": "off", | ||
"useLiteralEnumMembers": "warn", | ||
"useShorthandArrayType": "off", | ||
"noUnusedTemplateLiteral": "off" | ||
}, | ||
"complexity": { | ||
"noForEach": "off", | ||
"noExcessiveCognitiveComplexity": { | ||
"level": , | ||
"options": { | ||
"maxAllowedComplexity": 25 | ||
} | ||
}, | ||
"useLiteralKeys": "off", | ||
"useArrowFunction": "", | ||
"useFlatMap": "" | ||
}, | ||
"suspicious": { | ||
"noArrayIndexKey": "", | ||
"noExplicitAny": "", | ||
"noImplicitAnyLet": "", | ||
"noDoubleEquals": "" | ||
}, | ||
"nursery": { | ||
"all": false | ||
} | ||
} | ||
}, | ||
"css": { | ||
"linter": { | ||
"enabled": true | ||
}, | ||
"parser": { | ||
"cssModules": true | ||
} | ||
}, | ||
"javascript": { | ||
"parser": { | ||
"unsafeParameterDecoratorsEnabled": true | ||
} | ||
} | ||
} | ||
|
||
``` | ||
hasit marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
## Links | ||
|
||
- [Biome Configuration](https://biomejs.dev/reference/configuration/) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.