Rewrote jquery plugin starting point with UMD support.