Fix browserify shims.

- Add global shim
- Ensure that app / lib files are loaded without any issues.
- Refactor entities to use a namespace file.