GuestNo new alerts

Golang or TypeScript for Frontend

- Articles1366
I'm thinking of using Golang or TypeScript for the front-end, as it's the source of quite a few odd bugs and other oddities, I think we could benefit from strong typing here.

TypeScript would be complicated, as it would add another dependency to Gosora (Node), one which I'd like to avoid if possible. The easier it is to throw Gosora up, the better. That said, Node is probably present everywhere.

Another option is Go. We already use Go on the back-end and it works beautifully there. We could use it on the front-end as-well with something like GopherJS, although it might be a little intimidating for theme designers / front-end developers in contrast to TypeScript.
So far, I've just been transpiling little bits and pieces to JavaScript manually, while avoid GopherJS as while great on paper, the files it generated were so ridiculously big that it would weigh Gosora down to the bottom of the ocean.

One thing I have in mind however, is possibly to adopt WebAssembly at some point, as it should be coming out in the coming months in Go 1.11 and will hopefully be many degrees more optimised.