Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configure Prettier to lint all sort of files #35

Closed
gmarty opened this issue Jun 1, 2018 · 3 comments
Closed

Configure Prettier to lint all sort of files #35

gmarty opened this issue Jun 1, 2018 · 3 comments
Labels
question Further information is requested

Comments

@gmarty
Copy link

gmarty commented Jun 1, 2018

On my code base, I run Prettier with the following yarn task:

"prettier": "prettier --write \"**/*.{js,json,css,md}\""

When pretty-quick is run, it only apply Prettier on .js files, not the other types of file (e.g. .json, .css, .md...).

Is there a way I can instruct pretty-quick to work on these file types as well?

@azz
Copy link
Member

azz commented Jun 2, 2018

Are you sure? pretty-quick isn't extension aware, it should format any file types that are supported by prettier.

@azz azz added the question Further information is requested label Jun 2, 2018
@azz
Copy link
Member

azz commented Jun 2, 2018

$ echo >> README.md
$ yarn pretty-quick
yarn run v1.3.2
$ ./bin/pretty-quick.js
🔍  Finding changed files since git revision de790a7.
🎯  Found 1 changed file.
✍️  Fixing up README.md.
✅  Everything is awesome!
✨  Done in 0.71s.

@gmarty
Copy link
Author

gmarty commented Jun 5, 2018

Thanks for your answer. Did a check again and it seems to work. Closing.

@gmarty gmarty closed this as completed Jun 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants