prettifier icon indicating copy to clipboard operation
prettifier copied to clipboard

Feature : add support for prettier-standard

Open ritz078 opened this issue 8 years ago • 3 comments

https://github.com/sheerun/prettier-standard

It is really helpful as I can get rid of .eslintrc or prettier-eslint . Mostly useful for tiny modules. Let me know if you will accept a PR for this.

ritz078 avatar Sep 16 '17 22:09 ritz078

That's actually super similar to a feature I'm working on right now. Let me push the branch and show you what I mean. We can probably join our efforts :)

nettofarah avatar Sep 16 '17 22:09 nettofarah

https://github.com/nettofarah/prettifier/tree/format

@ritz078 I'm thinking of adding an option to allow for fixing your whole project. So basically you'd something like: prettifier --format **/**.js and it would fix your project for you.


As for prettier-standard. I'm not sure how bringing standard into the mix would work. I'm afraid we'd be making the package way too opinionated, but I think we should at least chat about the option.

nettofarah avatar Sep 16 '17 22:09 nettofarah

When people use prettier (formatter), most of the times they will also use eslint (linter) as both serve different purposes as the prettier you will be able to format the code but still, it won't check for some eslint rules that you might want.. The alternatives are :

  • use prettier-eslint - In this case it will run eslint --fix after prettier. You still need to setup eslintrc
  • use prettier-standard - It does the same as above but I think there's no need to setup eslint in this case. This one is easier to setup and minimizes the mess.

We can ask the user at the start whether he wants prettier or prettier-standard as we already have inquirer setup. So it won't be opinionated but configurable.

ritz078 avatar Sep 16 '17 23:09 ritz078