JS Asteroids

An implementation of wxAsteroids in Javascript using UHC (Utrecht Haskell Compiler)

View the Project on GitHub UU-ComputerScience/js-asteroids

Author: Ruben de Gooijer

wxAsteroids on the web

The original running on Windows
The stripped version running on Ubuntu
The port running in Chromium
The original wxAsteroids is a clone of the famous astroids game implemented in Haskell interfacing to the underlying C++ wxWidgets library and only runs on a desktop PC. The web port is accomplished by replacing a limited subset of wxWidgets with a Haskell implementation and uses the Utrecht Haskell Compiler (UHC) to compile the sources down to JavaScript. The key enabler is a library for OOP programming in Haskell which allowed the existing OO interface to remain intact while swapping out the implementation.

The port consists of three parts: For more details on the implementation and motivation please look at my master thesis. The source code and installation instructions can be here.