#hello i am just start to leaern devisnt there a ts e.g. for workers+ R2?there're onlt js...only
9 messages · Page 1 of 1 (latest)
You can use Typescript with a Worker, yes.
The types package is called @cloudflare/workers-types
no... i mean i need examples for ts
R2 is exactly the same in Javascript as Typescript except that in Typescript you get autocomplete and other Typescript functionality
But the actual function calls are identical
okay hard to understand to me who is very beginner of dev...thank your for your advice
Typescript is an extension of JS, basically. Everything you can do in JS you can do in Typescript. What Typescript adds is autocomplete in your editor and type safety (extra errors at build time when you do something wrong). But any example that works with JS will usually work with Typescript.