Hacker Newsnew | past | comments | ask | show | jobs | submitlogin



> --tab-width

> --single-quote

I mentioned.

> --use-tabs

Relates to the "indentation width."

> --print-width

Yes, that's another big user-configurable parameter.

> --trailing-comma

This exists only for JS version compatibility.

> --no-semi

> --no-bracket-spacing

> --arrow-parens

Yeah, those are there too.

---

But that's really it for JavaScript formatting options. Like I said, this produces very standardized code in the ecosystem.

Compare to clang-format (which suports JavaScript): http://releases.llvm.org/5.0.0/tools/clang/docs/ClangFormatS...


clang-format is nice but it's closer to eslint than Prettier. It does a lot more than just enforcing what the code looks like.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: