DEV Community

Mr_SC
Mr_SC

Posted on

Is typescript "static typing" features going to be imported in the js language overtime?

The story

I was discussing with a friend on the rise and decline of jQuery, Q and other libraries that were specifically build to solve a specific problem or feature missing in the javascript language.

This has made me think about the current libraries that drive today's websites and application and TYPESCRIPT was the one that spark my interest.

What is Typescript

TypeScript is a superset of JavaScript which primarily provides optional static typing, classes and interfaces.

My thought

Typescript offer a specific feature, static typing, that when was first announced raised quite a few eyebrows.

If you would have asked me the following question on any other feature, I would have immediately thought that sooner or later a feature (if useful) will eventually be included in the actual Javascript language, but static type is all another story. It is what makes Javascript "different".

The question

Do you guys think, that sooner or later ALL feature offered by typescript (even the static type) will be imported int he Javascript language? Even if it will mean for the language to be forked into two different mainstream?

Top comments (1)

Collapse
 
rhymes profile image
rhymes

Any JavaScript is valid TypeScript, correct?

TypeScript has optional static typing and interfaces, it also has JavaScript as a compilation target.

JavaScript is a dinamically and weakly typed language and I don't see that changing anytime.

So, what's left is interfaces? But interfaces in TypeScript require types.

I don't think there will be much in terms of "imports" from TS to JS