Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tracking: support typescript as the scripting language #30

Open
neverchanje opened this issue Dec 20, 2023 · 1 comment
Open

Tracking: support typescript as the scripting language #30

neverchanje opened this issue Dec 20, 2023 · 1 comment

Comments

@neverchanje
Copy link
Contributor

neverchanje commented Dec 20, 2023

The background shared by @pigpigyyy:

Teal was introduced a long while ago in this project when Typescript was not yet mature. However, when it comes to a statically typed scripting language, Typescript has grown to be the most popular option today. We can explore the possiblity of transpiling TS to Lua https://github.com/TypeScriptToLua/TypeScriptToLua and provide the type definitions for Dorothy like https://github.com/hazzard993/love-typescript-definitions

Eventually, we may also need to provide a template project for scaffolding.
https://github.com/hazzard993/love-typescript-template

@pigpigyyy
Copy link
Member

Thank you for your suggestions. I've successfully integrated the TypeScriptToLua compiler with our Dora SSR project, and have added several tests to the repository to ensure its functionality. We now support TypeScript by allowing the Web IDE to compile TS and TSX code into Lua whenever the editor's save action is triggered. We plan to introduce support for npm-based toolchains in the future, which will allow developers to work with their preferred external IDEs rather than being confined to the Dora SSR Web IDE.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants