A couple of weeks ago we announced the rewrite of RISE core in TypeScript.

TypeScript is a free and open-source programming language developed and maintained by Microsoft. It is a strict syntactical superset of JavaScript, and adds optional static typing to the language.

Wikipedia

What we achieved so far

Before we dive deeply into the current status of the TypeScript rewrite, I’d like to briefly recap what RISE has achieved so far.

Since Aug 2017 three new developers joined RISE: Alessio (carbonara), Jose (jguidos) and Matteo (mcanever).

Tests are truly crucial in the world of crypto code; these last few months our developers were mainly focused on writing unit tests for the current RISE codebase reaching a nice 68% code coverage (starting from almost zero).

Code coverage ramp up.

In the meanwhile I set up Travis and coveralls integration + slack integration to really streamline the development process.

In the public Github repository we can now count more than 90 commits and 38 closed pull requests.

The needs

When I first joined the RISE development team I immediately expressed my thoughts about the current status of the Core code which was entirely written in JavaScript. While I personally like JavaScript there is a very strong reason why most big web projects are written in TypeScript and not in JS: TypeScript lets you write much more robust and readable code that will also speed up development and future code refactoring.

Without flooding you with too many development details you should also know that code written in TypeScript usually benefits a 15% bug reduction compared to the same codebase written in plain EcmaScript (or Javascript). I’m sure you can imagine how crucial it is that bugs are eliminated in the blockchain world and why that 15% really matters (among all the other wonders of TypeScript).

The current status

The current RISE core code is already 100% TypeScript; one month ahead of my predicted deadline.

But, when porting the code from JS to TS I personally noticed some bad coding practices inherited by previous developers of the RISE core.