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

Consider using AST-based TypeScript code generation #153

Open
dslmeinte opened this issue Apr 26, 2024 · 3 comments
Open

Consider using AST-based TypeScript code generation #153

dslmeinte opened this issue Apr 26, 2024 · 3 comments

Comments

@dslmeinte
Copy link
Contributor

dslmeinte commented Apr 26, 2024

See e.g.: https://nabeelvalley.co.za/docs/javascript/typescript-ast/

This might also be useful to make pluggable code generators, e.g. generating code specifically for Freon.

Is it possible to use a ParseExpression feature like Roslyn has?

@joswarmer
Copy link
Contributor

At first sight this looks harder than just using a (text) template. But maybe first sight is misleading :-).

@dslmeinte
Copy link
Contributor Author

@dslmeinte
Copy link
Contributor Author

Two advantages of this approach is that we're already using an intermediate representation, and that potentially things like cross-file imports could become a bit easier.

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