Last active
December 19, 2015 21:19
-
-
Save wrumsby/6019354 to your computer and use it in GitHub Desktop.
Detecing AMD support
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (function (global) { | |
| 'use strict'; | |
| var ristretto = { | |
| // ... | |
| }; | |
| if (typeof define === 'function' && define.amd) { | |
| define([], function () { | |
| return ristretto; | |
| }); | |
| } else { | |
| global.ristretto = ristretto; | |
| } | |
| }(window)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment