Shopify / theme-tools

Everything developer experience for Shopify themes
https://shopify.dev/docs/themes
MIT License
75 stars 22 forks source link

Bake prettier formatting inside the Language Server (instead of the VS Code extension) #26

Open charlespwd opened 1 year ago

charlespwd commented 6 days ago

There's a significant difference in what the browser accepts and what desktop accepts for prettier:

Run Prettier in the browser using its standalone version. This version doesn’t depend on Node.js. It only formats the code and has no support for config files, ignore files, CLI usage, or automatic loading of plugins.

I'm assuming it's because of the same problem we have with loadConfig in browser settings. You can't run node_module code in browser, so .prettierrc.js files are doomed.

I'm considering closing this and only leaving that behaviour in the VS Code extension. IDK how I'd resolve that kind of dependency injection.