refactoring to make object live in the javascripture namespace