Created
April 16, 2018 04:11
-
-
Save LeeeeeeM/14d2b76566b542208bf3c9589444a8df to your computer and use it in GitHub Desktop.
UMD
This file contains 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 (root, factory) { | |
if (typeof define === 'function' && define.amd) { | |
// AMD. Register as an anonymous module. | |
define([], factory); | |
} else if (typeof exports === 'object') { | |
// Node. Does not work with strict CommonJS, but | |
// only CommonJS-like environments that support module.exports, | |
// like Node. | |
module.exports = factory(); | |
} else { | |
// Browser globals (root is window) | |
root.returnExports = factory(); | |
} | |
}(this, function () { | |
// Just return a value to define the module export. | |
// This example returns an object, but the module | |
// can return a function as the exported value. | |
return {}; | |
})); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment