Rewrite code base to use typescript for easier maintenance and documentation

I think that rewriting the code base to typescript will make it easier to maintain and understand. Better understanding of the API and integration of the different parts.
This change can be gradual.

2 Likes

Do you have any thoughts on where to begin?

I would say the best start would be to setup existing code as a typescript project.
There is no need initially to change any of the existing code, Maybe only the index.js.
This article explains it very well:
https://khalilstemmler.com/blogs/typescript/node-starter-project/

Then a multistage Dockerfile should be created.
Example:
https://medium.com/@ankit.wal/the-why-and-how-of-multi-stage-docker-build-with-typescript-example-bcadbce2686c

Actual coversion to typescript can be done later and gradually.

2 Likes

Are you in a position to help us out with a draft PR?

Thanks for the documentation, by the way!

1 Like

It’s a large effort, but we’d welcome contributions for sure!

2 Likes

I’m not free right now. I’ll try to make a draft PR in the next 2 weeks I hope.

1 Like

I’ve created a draft PR.
Still need to add documentation and tests on how to build

2 Likes

PR is ready for review

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.