Codesandbox-client: Allow for using workspace TypeScript version

Created on 15 Apr 2020  Â·  3Comments  Â·  Source: codesandbox/codesandbox-client

🌈 Feature


Allow for using the TypeScript version of the project itself inside VSCode.
image

To make this work we need to write TypeScript to node_modules of the project. We can do this by running:

const fs = BrowserFS.BFSRequire('fs');

// ... Now write all files of TS to the folder, we should probably fetch them from a tar from npm registry or from unpkg.com
fs.writeFileSync('/sandbox/node_modules/typescript');
// And repeat...


We could implement this maybe within our sandbox fs syncer: https://github.com/codesandbox/codesandbox-client/blob/master/packages/app/src/app/overmind/effects/vscode/SandboxFsSync/index.ts#L1

✨ Feature

Most helpful comment

That would be nice! I just tried adding a .vscode/settings.json with typescript.tsdk pointing to node_modules/typescript/lib for TypeScript 4.0, but it's not working. Looks like it doesn't find the tsserver.js file.

All 3 comments

This issue is stale because it has been open many days with no activity. It will be closed soon unless the stale label is removed or a comment is made.

That would be nice! I just tried adding a .vscode/settings.json with typescript.tsdk pointing to node_modules/typescript/lib for TypeScript 4.0, but it's not working. Looks like it doesn't find the tsserver.js file.

Hey!

We are keeping track of all our features in a backlog in notion so I am gonna move this over there.

It gets more visibility to us there

Was this page helpful?
0 / 5 - 0 ratings

Related issues

supersonicclay picture supersonicclay  Â·  3Comments

Haroenv picture Haroenv  Â·  3Comments

MarcelloTheArcane picture MarcelloTheArcane  Â·  3Comments

alansouzati picture alansouzati  Â·  3Comments

wojciechczerniak picture wojciechczerniak  Â·  3Comments