]> git.ipfire.org Git - thirdparty/moment.git/commitdiff
RequireJS (AMD) support added 130/head
authorMalte Legenhausen <mlegenhausen@gmail.com>
Wed, 11 Jan 2012 21:51:49 +0000 (22:51 +0100)
committerMalte Legenhausen <mlegenhausen@gmail.com>
Wed, 11 Jan 2012 21:51:49 +0000 (22:51 +0100)
moment.js

index 5e64b10e2cebcf2258914109a543eacf35306aa5..f3db3e530da6c917215399a5d52a2a8cf62fb78f 100644 (file)
--- a/moment.js
+++ b/moment.js
     if (typeof window !== 'undefined') {
         window.moment = moment;
     }
-
+    if (typeof define === "function" && define.amd) {
+       define( "moment", [], function () {
+            return moment;
+        });
+    }
 })(Date);