[go: nahoru, domu]

Skip to content
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

lsp: should work with local node_modules directory #16373

Closed
Tracked by #15960
dsherret opened this issue Oct 20, 2022 · 1 comment · Fixed by #19203
Closed
Tracked by #15960

lsp: should work with local node_modules directory #16373

dsherret opened this issue Oct 20, 2022 · 1 comment · Fixed by #19203

Comments

@dsherret
Copy link
Member
dsherret commented Oct 20, 2022

From #16332

LSP doesn't work with local node_modules directory since there's no configuration for this at the moment. I think we should consider making this an option in the deno.json file or perhaps it should detect if there's a node_modules folder and prefer to use that?

When we add suport for this we'll need to ensure it initializes the npm snapshot from the lockfile to ensure it resolves the same as on the command line (otherwise there will be a lot of churn in the node_modules folder).

@bartlomieju
Copy link
Member

@dsherret is this issue still relevant?

dsherret added a commit that referenced this issue May 23, 2023
This adds support for the lockfile and node_modules directory to the
lsp.

In the case of the node_modules directory, it is only enabled when
explicitly opted into via `"nodeModulesDir": true` in the configuration
file. This is to reduce the language server automatically modifying the
node_modules directory when the user doesn't want it to.

Closes #16510
Closes #16373
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants