-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does not seem to work with overrides #200
Comments
Sorry for the prod @fsouza , any updates on this? |
@petertriho Seems like a problem with prettier itself (see here) For now, though, you can just create an editorconfig with the following options: [*.{yaml,yml,md}]
indent_style = spaces
indent_size = 2 |
Yeah looking at that issue, it looks like when resolveConfig is invoked overrides should work, and we do invoke resolveConfig. Maybe we're not setting the right parameters for the file type or something like that? |
@fsouza the problem has to do with how you cache values in configuration files. If I run prettierd with overrides in a config file, it works. If I change that config file, it doesn't. These lines of code cache configurations according to files... but if the configuration file changes, prettierd completely ignores the new changes and just uses the cache. I think you can either completely remove the config cache (would it really hurt performance that bad), figure out a way to invalidate files in the cache (which sounds annoying), or see how prettier did it. Willing to write a PR for any of those solutions, let me know. |
I can't seem to get overrides to work with this config (
.prettierrc.json
). Changing the roottabWidth
works but my overrides do not work for the specific files.The text was updated successfully, but these errors were encountered: