gajus / format-graphql

Formats GraphQL schema definition language (SDL) document.
Other
71 stars 8 forks source link

Support for globs #15

Open jens1101 opened 4 years ago

jens1101 commented 4 years ago

Currently we have multiple GraphQL files in our source code and I need to run this for each file individually. It would be much more convenient if globs were supported. Then I could run something like:

npx format-graphql --write=true ./src/**/*.graphql
gajus commented 4 years ago

If you are using lint-staged, then you can already do that:

https://github.com/okonet/lint-staged#example-wrap-filenames-in-single-quotes-and-run-once-per-file