Cleaned up JS namespacing. Added minified version