The postinstall script now adds the--single-quote --trailing-comma all flags to the prettier command in package.json. This works well for the precommit hook, but if the developer has enabled a prettier-plugin in the editor which prettifies the files on save, those rules aren't picked up, but need to be separately specified in a .prettierrc file leading to duplication and potential WTFs.
If the postinstall script instead would create the aforementioned .prettierrc and place the rules there, the precommit hook and potential editor-plugins would read the rules from that file and everyone is 🌞
The postinstall script now adds the
--single-quote --trailing-comma all
flags to the prettier command in package.json. This works well for the precommit hook, but if the developer has enabled a prettier-plugin in the editor which prettifies the files on save, those rules aren't picked up, but need to be separately specified in a .prettierrc file leading to duplication and potential WTFs.If the postinstall script instead would create the aforementioned .prettierrc and place the rules there, the precommit hook and potential editor-plugins would read the rules from that file and everyone is 🌞
Any problems with this?