Cleanup and documentation of web lib