Open kkweon opened 6 years ago
You could fix this using the custom variable prettier-js-args
to specify the prettier parse you want to use.
And can still be used to format js, ts, json, less, scss ? It will force the parser?
Yes, it forces the parser. You will have to set the variable to the right format for each one of these files. You could do this with hooks for example.
Edit: If you need more info on the prettier args you can run prettier --help
in the command line.
Sorry to revive an old thread, but perhaps prettier
could infer a reasonable extension from the major mode when there is no buffer-file-name
, as is the case in org-mode source blocks?
Steps to reproduce
temp.org
prettier-js
Thank you.