
* 特性
@gitopslovers/nx-biome 提供一套供电 无 以 生物体。 。 。 .
- 执行者: 提供一些执行器, 用于用 Biome 添加、格式化和分析您的文件 .
- 发电机:帮助您配置您的项目.
- 配置: Biome 的每个项目配置扩展工作空间配置.
- 仅受影响: 使用 Nx 支持仅对受影响的项目进行林入格式化和分析.
- 缓存: 使用 Nx来缓存已触碰的工程 .
* 安装
使用 无
npm i -D @gitopslovers/nx-biome
为一个项目配置生物体
要在一个项目中添加 Biome 配置, 您只需运行 @gitopslovers/nx-biome:configuration 发电机.
nx g @gitopslovers/nx-biome:configuration --project <projectName>
发电机加了一个 biome.json 工程根上延伸根的配置文件 biome.json 添加一个 biome-lint 目标到项目.
在第一次运行时,生成器安装所有必要的依赖性并创建一个 biome.json 在工作空间根处的文件。 它也会配置 namedInputs 联 合 国 biome-lint 目标.
实例
运行 biome-lint 项目
nx biome-lint {{projectName}}
运行 biome-lint 所有项目
nx run-many --target=biome-lint
运行 biome-lint 受影响的项目
nx affected --target=biome-lint
页:1
@gitopslovers/nx-biome:configuration 发电机
在项目中添加 Biome 配置 .
使用量
向工程添加配置 :
nx g @gitopslovers/nx-biome:configuration --project projectName
选项
| 选项 | 数值 | 说明 |
|---|---|---|
project | string | 项目名称. |
@gitopslovers/nx-biome:biome-lint 执行器
在一个项目上运行 Biome linter.
目标选项可以配置在 project.json 或当执行人被援引.
见: https://nx.dev/configulation/projectjson#目标
选项
| 选项 | 数值 | 默认 | 说明 |
|---|---|---|---|
lintFilePatterns | string[] | 一个或多个文件/ dirs/ globs 直接传递到 Biome 的 lint () 方法 . |