Pooped on the code to make it run in browser too. V1.10

Should really get those tests running...