The WebGL programming model has a lot of shortcoming from a modern point of view, see here: http://floooh.github.io/2016/08/13/webgl-next.html (you can mostly ignore my criticism of adopting Vulkan for the web, the Mozilla proposal (called Obsidian) is pretty close to Vulkan, and doesn't look as bad as I feared when I wrote that blog post).