Parser error on Typescript in code editor



I get an parser error on Typescript in the code editor, seems strange that Glitch doesn’t support Typescript. I’m getting a parser error on a: in the below snippet

let adder = function(a: number, b:number) {
return a + b;

Can I use the code editor for Typescript?



That error comes from our linter. It won’t affect the way your project executes. If you’re using TypeScript, you will have to set up a compilation step in your project - you can’t just use it with the default Node setup.


Here’s one such compilation setup you can remix:


Thanks for getting back to me, I used the tsc command in the console to compile this one file. Just didn’t get why the linter of the code editor wasn’t tackling TypeScript syntax.
I would like to refer our community to Glitch demo’s for explaining Node.js && TypeScript with Highcharts. Then it would be nice to get rid off the parser error messages. Glitch is awesome btw, thanks!!