Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Update UMD template and README

  • Loading branch information...
commit 6677e7a045b67052e5b04441ca0de598037e88d4 1 parent 914c591
@hpneo authored
Showing with 22 additions and 16 deletions.
  1. +2 −0  README.md
  2. +10 −8 gmaps.js
  3. +10 −8 umd.hbs
View
2  README.md
@@ -23,6 +23,8 @@ Changelog
0.4.9
-----------------------
+* Add UMD support (AMD, CommonJS, browser globals)
+* Add retina support
* FitZoom only use visible markers
0.4.8
View
18 gmaps.js
@@ -1,14 +1,15 @@
(function(root, factory) {
- if(typeof exports === 'object') {
- module.exports = factory();
- }
- else if(typeof define === 'function' && define.amd) {
- define('GMaps', [], factory);
- }
+ if(typeof exports === 'object') {
+ module.exports = factory();
+ }
+ else if(typeof define === 'function' && define.amd) {
+ define('GMaps', [], factory);
+ }
- root.GMaps = factory();
+ root.GMaps = factory();
}(this, function() {
+
/*!
* GMaps.js v0.4.9
* http://hpneo.github.com/gmaps/
@@ -2059,5 +2060,6 @@ if (!Array.prototype.indexOf) {
return -1;
}
}
- return GMaps;
+
+return GMaps;
}));
View
18 umd.hbs
@@ -1,14 +1,16 @@
(function(root, factory) {
- if(typeof exports === 'object') {
- module.exports = factory({{{cjsDependencies}}});
- }
- else if(typeof define === 'function' && define.amd) {
- define({{#if amdModuleId}}'{{amdModuleId}}', {{/if}}[{{{amdDependencies}}}], factory);
- }
+ if(typeof exports === 'object') {
+ module.exports = factory({{{cjsDependencies}}});
+ }
+ else if(typeof define === 'function' && define.amd) {
+ define({{#if amdModuleId}}'{{amdModuleId}}', {{/if}}[{{{amdDependencies}}}], factory);
+ }
- root.{{globalAlias}} = factory({{{globalDependencies}}});
+ root.{{globalAlias}} = factory({{{globalDependencies}}});
}(this, function({{dependencies}}) {
+
{{{code}}}
- return {{objectToExport}};
+
+return {{objectToExport}};
}));
Please sign in to comment.
Something went wrong with that request. Please try again.