Reorganized for bower packaging, added amd/commonjs wrapper