Devpost: devpost.com/software/edge-5c3igw
Video explanation and demo: youtu.be/v7RG2VQnrhg
Gitlab repo: gitlab.com/fakeoaks2021/edgepp
Edge++ is a working, though not deployed due to security concerns, proof of concept for a way to enable programming interactive websites with no javascript and instead use basic C++ or possibly also C. Its target are students who know one of those two languages and want to make a simple interactive webpage but cannot or do not want to learn javascript. This would enable them to create websites sooner and find practical use for their developing programming skills. For universities, this could be used to aid in introductory programming courses to allow for some projects beyond the command line.
Edge++ is the project that our team fakeoaks developed and presented at Hackupc 2021, an online (due to COVID-19) 36-hour hackathon. Our team was composed of Dani Vilardell, who is a mathematics and telecomunications student at UPC and Ruben Aciego, Jofre Costa and myself, the three of us mathematics and computer science/engineering students also at UPC.
The main technology behind the project is WebAssembly (WASM) and more specifically WASI. We developed js code to allow the communication between the WASM-compiled C++ code so that to the C++ side it seemed to be running on a normal command line. We also invented a text API to communicate between the website and C++. The project also has an automatic compiling, bundling and deployement system.
The main problem we had to solve was how to work around the single-threadedness
of javascript (js is still used in the website to start up the C++ code) without
having to make the C++ programmer aware of any of that. That meant somehow
getting the input to be blocking but also not blocking the webpage itself.
In the end we were able to use service workers and sharedbufferarrays
to
solve that hurdle.