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

Use workspace TS version in VSCode #817

Merged

Conversation

namuol
Copy link
Contributor

@namuol namuol commented Apr 15, 2023

By default, VSCode uses its built-in TypeScript version, which is currently 5.x, however langchainjs is using 4.x for its build, so it's possible for contributors to see errors in their editor that don't match the output from the build, or vice-versa.

This default behavior surprised me; it bit me a few times while working on an experiment to improve type-coverage for prompts, as there were changes to how types are inferred in TS 5.

This PR modifies the VSCode workspace settings to use the version from the workspace (4.x), rather than VSCode's built-in version, which should hopefully save contributors the same frustrations.

To do this I just used the Select TypeScript version command from VSCode, like so:

Screen.Recording.2023-04-15.at.10.59.44.AM.mov

@vercel
Copy link

vercel bot commented Apr 15, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
langchainjs-docs ✅ Ready (Inspect) Visit Preview Apr 15, 2023 6:08pm

@nfcampos
Copy link
Collaborator

nfcampos commented May 5, 2023

Thanks

@nfcampos nfcampos merged commit b58552f into langchain-ai:main May 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants