Skip to content

Commit

Permalink
docs: readme
Browse files Browse the repository at this point in the history
  • Loading branch information
guoyunhe committed Feb 7, 2024
1 parent fbd7db9 commit bd8af3f
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions packages/f2elint/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,28 @@

f2elint 是《阿里巴巴前端规约》的配套初始化工具,可以为各种前端和 Node.js 项目一键接入规约,保障项目的编码规范和代码质量。

## CLI

```bash
npx f2elint
```

![screenshot](https://github.com/alibaba/f2e-spec/assets/5836790/80b5c4fd-6ab1-4423-8ae5-0572777db0a7)

## API

```bash
npm install --save f2elint
```

```js
import { f2elint, TemplateType } from 'f2elint';

await f2elint('path/to/project/root', {
template: TemplateType.ReactTS,
stylelint: true,
prettier: true,
lintStaged: true,
commitlint: false,
})
```

0 comments on commit bd8af3f

Please sign in to comment.