utilities for writing JS classes and objects in Opal