prettier / prettier-emacs

Minor mode to format JS code on file save
http://jlongster.com/A-Prettier-Formatter
372 stars 53 forks source link

Sync Prettier options to buffer-local variables #44

Closed jscheid closed 5 years ago

jscheid commented 5 years ago

This syncs various Prettier options, such as printWidth and useTabs, to the corresponding Emacs variables, such as js-indent-level.

Emacs variables are set for a number of major modes for languages that Prettier supports either directly or through plug-ins.

Buffer-local variables are removed or restored to their previous value when prettier-js-mode is disabled, unless the variable was changed since prettier-js-mode was enabled.

jscheid commented 5 years ago

I've decided to implement this in https://github.com/jscheid/prettier.el instead.