You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add TypeScript types and maybe publish to NPM. Or maybe Teal instead? #3
Some Lua / CC projects makes use TypeScript rather then regular Lua but it gets traspiled to regular Lua using TypeScriptToLua. They do this for a better IDE experience and to use advance fetures like classes (which Lua does not nativly support without hacks).
It is possibile to import regular Lua files in such an envrionment however the IDE will complain about missing type definitions.
Whilst it is possible for the project to make their own type defitions for Basalt - it would be better if Basalt came with their own.
Furthermore, you can publish Basalt to NPM (which publishing Lua scripts is allowed) to make it easier for TSTL based projects to use.
You don't have to replace your existing Lua files with TypeScript - we just need type declaration files - actually you just need one basalt.d.ts file inside your release folder.
For anyone intersected, here is my version of mappings. It is not complete by any means, because it covers only things that I used, but it is usable to some extent.
changed the title [-]Add TypeScript types and maybe publish to NPM.[/-][+]~~Add TypeScript types and maybe publish to NPM.~~ Or maybe Teal instead?[/+]on Apr 5, 2026
changed the title [-]~~Add TypeScript types and maybe publish to NPM.~~ Or maybe Teal instead?[/-][+]~Add TypeScript types and maybe publish to NPM.~ Or maybe Teal instead?[/+]on Apr 5, 2026
changed the title [-]~Add TypeScript types and maybe publish to NPM.~ Or maybe Teal instead?[/-][+]Add TypeScript types and maybe publish to NPM. Or maybe Teal instead?[/+]on Apr 5, 2026
Activity
SirEdvin commentedon Sep 28, 2025
I would double this, having typescript mappings would be very cool
SirEdvin commentedon Nov 1, 2025
For anyone intersected, here is my version of mappings. It is not complete by any means, because it covers only things that I used, but it is usable to some extent.
samuelh2005 commentedon Apr 5, 2026
Perhaps Teal could be used instead? It is Lua with types. This means we don't have to rewrite Basalt in TypeScript.
[-]Add TypeScript types and maybe publish to NPM.[/-][+]~~Add TypeScript types and maybe publish to NPM.~~ Or maybe Teal instead?[/+][-]~~Add TypeScript types and maybe publish to NPM.~~ Or maybe Teal instead?[/-][+]~Add TypeScript types and maybe publish to NPM.~ Or maybe Teal instead?[/+][-]~Add TypeScript types and maybe publish to NPM.~ Or maybe Teal instead?[/-][+]Add TypeScript types and maybe publish to NPM. Or maybe Teal instead?[/+]