-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs(eslint-config-typescript): add the usage section of README.md
- Loading branch information
1 parent
a6ded86
commit 0c40fe3
Showing
2 changed files
with
28 additions
and
1 deletion.
There are no files selected for viewing
This file contains 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 |
---|---|---|
@@ -1,2 +1,29 @@ | ||
# ESLintConfig | ||
> The ESLint Config Be Used For AllJointNext | ||
## Usage | ||
1. Installation | ||
```sh | ||
yarn add eslint prettier @alljoint-next/eslint-config --dev | ||
# npm install eslint prettier @alljoint-next/eslint-config --save-dev | ||
``` | ||
|
||
2. Setup Configuration | ||
```sh | ||
echo '{ "extends": "@alljoint-next" }' > .eslintrc.json | ||
echo '!**/node_modules/** | ||
!./node_modules/** | ||
!**/.{git,svn,hg}/** | ||
!./.{git,svn,hg}/**' > .eslintignore | ||
``` | ||
|
||
3. Add Scripts | ||
package.json | ||
```json | ||
{ | ||
"scripts": { | ||
"format": "prettier **/*.{js,json,md,yaml} --write && yarn lint --fix", | ||
"lint": "eslint **/*.js" | ||
} | ||
} | ||
``` |
This file contains 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 |
---|---|---|
@@ -1,7 +1,7 @@ | ||
{ | ||
"name": "@alljoint-next/eslint-config", | ||
"version": "0.1.0", | ||
"description": "The ESLint Config Used For AllJointNext", | ||
"description": "The ESLint Config Be Used For AllJointNext", | ||
"author": "TZU-YEN, CHANG <[email protected]>", | ||
"license": "GPL-3.0", | ||
"main": ".eslintrc.json", | ||
|