standard / vscode-standard

VS Code extension for JavaScript Standard Style (`standard`) with automatic fixing
https://marketplace.visualstudio.com/items?itemName=standard.vscode-standard
MIT License
121 stars 24 forks source link

Yarn PNP support #408

Open Suyashtnt opened 2 years ago

Suyashtnt commented 2 years ago

What version of this package are you using? latest

What problem do you want to solve? Adding support for yarn pnp

What do you think is the correct solution to this problem? use yarn run ts-standard instead of whatever is going on currently when a .pnp.cjs file is detected

Are you willing to submit a pull request to implement this change? Maybe ill try later

showaltb commented 1 year ago

I'm not qualified to create a PR for this, but could it be handled by implementing a setting to provide a custom command to run the linter? That way we could just use yarn run standard (or whatever) and the plugin wouldn't have to worry about PnP details.

Without this, the plugin runs the global version of standard, which is good, but has bitten me once or twice on some minor rule updates.

timchambers commented 7 months ago

I'm still having this issue with Yarn 4.0 which uses this PNP method that doesn't create a node_modules directory or expose binaries in the same fashion. Has anyone sorted out a workaround to get this working again when using Yarn?