indic-transliteration / sanscript.js

Transliteration package for Indian scripts
MIT License
98 stars 39 forks source link

Typescript definition #53

Closed grosmar closed 2 years ago

grosmar commented 2 years ago

Simple d.ts definition solution to support typescript integration

vvasuki commented 2 years ago

I am not familiar with Typescript - Does this alter the build process in any way? What benefits do we get from this?

grosmar commented 2 years ago

It does not have any effect on the native javascript implementation.

Typescript is a superset language over Javascript which introduces types at compile time. So people who write their project in typescript can use this type definition, so they know if they fulfill properly the syntax.

As I see there is already an open issue that requests supporting this: https://github.com/indic-transliteration/sanscript.js/issues/29