rnc-archive / .github

This repository contains the general guidelines for the RNCommunity org
https://github.com/react-native-community
200 stars 31 forks source link

Remove the flow parser from the recommended Prettier config #25

Closed matt-oakes closed 5 years ago

matt-oakes commented 5 years ago

This is not needed as Prettier picks the correct parser based on the file type (defaulting to flow for js, typescript for ts and tsx etc.). Hard coding it like this causes subtle issues with repos with mixed or purely Typescript code like this:

https://github.com/typescript-eslint/typescript-eslint/issues/481

Removing this does not affect users of Flow as it will be the default for JS files.