Skip to content
← Back to Community
TypeScript HTML5 Project?
Profile icon
h
has Hacker Plan
NimaiMalle

When I make a new JavaScript project, I get an index.html page and can do client-side coding. When I make a new TypeScript project, it looks like it's tailored to node server development. How can I make an html project that uses TypeScript? Thanks!

Voters
Profile icon
KennHamm
Profile icon
squeegily
Profile icon
solly_ucko
Profile icon
NimaiMalle
Comments
hotnewtop
Profile icon
squeegily

Ugh. This is killing me, too! So many client-side libraries use TypeScript, export, or a bunch of other stuff that needs to be compiled; I hate being unable to use these with replit...

Profile icon
NimaiMalle

I did try just renaming the index.js file to index.ts in simple web project. It went from working to not working - no error. TypeScript linting appeared to be going on in the IDE but when I run, I just get a blank screen for the "result" and no errors in the console.

I think what's needed is a new project type: "HTML, CSS, TS"

Profile icon
ArchieMaclean

Try making a html/js/css repl and make a typescript file? May not work though :P

Profile icon
NimaiMalle

@ArchieMaclean Yeah, that's the first thing I tried.

Profile icon
themaka

@NimaiMalle - you'll get a bit of extra stuff you may not need, but if you use https://repl.it/languages/reactts you'll get the ability to use TS with web technologies.

Profile icon
8Observer8

@themaka I cannot run this example. I see errors. How to run it?