Add UMD wrapper to work with Node.js, AMD, and browser globals