Recently, Prettier added support for storing the configuration in a project file.
https://github.com/prettier/prettier#configuration-file
Prettier uses cosmiconfig for configuration file support. This means you can configure prettier via:
- A .
prettierrcfile, written in YAML or JSON.- A
prettier.config.jsfile that exports an object.- A
"prettier"key in yourpackage.jsonfile.The configuration file will be resolved starting from the location of the file being formatted, and searching up the file tree until a config file is (or isn't) found.
AFAICT, the VSCode extension ignores this config now.
It would be great if the extension could load the config the same way how Prettier CLI does it, and then applying any VSCode-specific configuration as an override on top of that base configuration.
The use case I have in mind is to keep Prettier configuration in a single place and use it by several tools:
Not yet released. See #124
Lovely, let's close my issue as a duplicate then.
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Most helpful comment
The use case I have in mind is to keep Prettier configuration in a single place and use it by several tools: