fix(biome): find root when using biome.jsonc (#4774)

Since biome supports either `biome.json` or `biome.jsonc` config files,
we need to look for both when searching for the LSP project root. We can
also look for a package.json or .git folder to use. This uses mostly the
same logic as deno.
This commit is contained in:
Braden Kelley
2024-06-25 01:18:28 -07:00
committed by GitHub
parent e09520e2d7
commit ed0b036220
8 changed files with 68 additions and 2 deletions

View File

@@ -35,6 +35,22 @@ g:ale_biome_fixer_apply_unsafe *g:ale_biome_fixer_apply_unsafe*
If set to `1`, biome will apply unsafe fixes along with safe fixes.
g:ale_biome_lsp_project_root *g:ale_biome_lsp_project_root*
*b:ale_biome_lsp_project_root*
Type: |String|
Default: `''`
If this variable is left unset, ALE will try to find the project root by
executing the following steps in the given order:
1. Find an ancestor directory containing a biome.json.
2. Find an ancestor directory containing a biome.jsonc.
3. Find an ancestor directory containing a package.json.
4. Find an ancestor directory containing a .git folder.
5. Use the directory of the current buffer (if the buffer was opened from
a file).
===============================================================================
cspell *ale-typescript-cspell*