Starting attempt at making it work in the browser again.