Please describe what prettier ignores by default (#12626)

Co-authored-by: Szymon Dzialowski <sdzialowski@godaddy.com>
Co-authored-by: Szymon Dzialowski <sdzialowski@gmail.com>
Co-authored-by: fisker Cheung <lionkay@gmail.com>
This commit is contained in:
authored and GitHub committed 2022-04-12 17:47:07 +08:00
1 parent ae72b47477
commit c50f2bbe30
2 files changed
+42

No files matched your search

+21
View File
@@ -24,6 +24,27 @@ coverage
It’s recommended to have a `.prettierignore` in your project! This way you can run `prettier --write .` to make sure that everything is formatted (without mangling files you don’t want, or choking on generated files). And – your editor will know which files _not_ to format!
By default prettier ignores files in version control systems directories (".git", ".svn" and ".hg") and `node_modules` (if [`--with-node-modules` CLI option](cli.md#--with-node-modules) not specified)
So by default it will be
```js
**/.git
**/.svn
**/.hg
**/node_modules
```
and
```js
**/.git
**/.svn
**/.hg
```
if [`--with-node-modules` CLI option](cli.md#--with-node-modules) provided
(See also the [`--ignore-path` CLI option](cli.md#--ignore-path).)
## JavaScript