Open osyrisrblx opened 4 months ago
Supersedes roblox-ts/roblox-ts#2199
Is jsdelivr the preferred strategy? We could also install roblox-ts first, then parse the node_modules/roblox-ts/package.json
.
Copying the body from https://github.com/roblox-ts/roblox-ts/issues/2199
Running
rbxtsc init
will make the package manager install the latest (stable) version of TypeScript, not the actual version that roblox-ts is meant to support. This causes version conflicts, where for example the user's editor might show support for a new feature, but the compiler wouldn't yet recognise it.
We could also install roblox-ts first, then parse the
node_modules/roblox-ts/package.json
. This is possible, but I am concerned about having to runnpm install
twice. It's not a very fast command. 😓
I realized jsdelivr might have caching issues with @latest
.
Alternatively, we could do:
npm view roblox-ts@latest dependencies.typescript
(or swap @latest
for a specific version)
Whatever caching issues this has would probably match npm install
.
We can fetch + parse the package.json using jsdelivr.net
The end result should be like
"typescript": "=5.3.3",