mirror of
https://github.com/danswer-ai/danswer.git
synced 2025-03-26 17:51:54 +01:00
Specify specific prettier version (#186)
* Add explicit prettier version * Update CONTRIBUTING.md * Add .prettierrc.json file to ensure we always use es5 trailing commas
This commit is contained in:
parent
4b699fdab3
commit
9252807a51
@ -154,8 +154,8 @@ creating a pull requests with `python -m mypy .` from the `danswer/backend` dire
|
||||
|
||||
|
||||
#### Web
|
||||
We use `prettier` for formatting. Follow the guide [here](https://prettier.io/docs/en/install.html) to install, and run
|
||||
`npx prettier --write --trailing-comma es5 .` from the `danswer/web` directory to automatically format.
|
||||
We use `prettier` for formatting. The desired version (2.8.8) will be installed via a `npm i` from the `danswer/web` directory.
|
||||
To run the formatter, use `npx prettier --write .` from the `danswer/web` directory.
|
||||
Like `mypy`, we have no automated formatting yet (coming soon), but we request that, for now,
|
||||
you run this manually before creating a pull request.
|
||||
|
||||
|
3
web/.prettierrc.json
Normal file
3
web/.prettierrc.json
Normal file
@ -0,0 +1,3 @@
|
||||
{
|
||||
"trailingComma": "es5"
|
||||
}
|
@ -30,5 +30,8 @@
|
||||
"tailwindcss": "^3.3.1",
|
||||
"typescript": "5.0.3",
|
||||
"yup": "^1.1.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"prettier": "2.8.8"
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user