4 ms·
This look very promising. We are increasingly using a subset of typescript in our backend so as to be amenable to a tool, in the long run, which can convert th
by elendilm 3mo ago
This look very promising.
We are increasingly using a subset of typescript in our backend so as to be amenable to a tool, in the long run, which can convert the ts subset to rust source code.
This project will enable an alternative of that vision earlier - except of course without the parallelism.
Also I am curious as to whether this will compile to a static lib which can be linked to an existing cpp app to be run on android/ios targets. In theory it should be able to. The docs mention ffi, but I didn't dig deep.
- aluxian 3mo agoDoes that tool already exist, so do you have a specific TS subset in mind you are aiming for? Or you are simply trying to use fewer complex features?
- elendilm 3mo agoNo the tool does not exist. Its medium to long term vision. Our backends are structured on isolated units - what we call "features". Features invoke another features via fully qualified names using a standard Features.send(...). in-process/inter-replica/inter-service and even seperate functions inside the same js files are all invoked likewise. Only a few specific helper functions for a feature exist for direct invocations. The complexity of ts2rust tool is thus greatly reduced because of the discipline of the architecture.