mirror of
https://github.com/NASAWorldWind/WebWorldWind.git
synced 2025-12-08 19:46:18 +00:00
- This changes the build artifact generation so it has a UMD interface. http://davidbcalhoun.com/2014/what-is-amd-commonjs-and-umd/ - Build artifacts should now be capable of working like a Node modules (as an npm package with a bundler like Webpack or Browserify for frontend development), in addition to the previous interfaces (an AMD module or web browser object attached to the window object).
14 lines
339 B
Plaintext
Executable File
14 lines
339 B
Plaintext
Executable File
(function (root, factory) {
|
|
if (typeof exports === "object") {
|
|
// CommonJS-like
|
|
module.exports = factory();
|
|
} else if (typeof define === 'function' && define.amd) {
|
|
// AMD.
|
|
define([], factory);
|
|
} else {
|
|
// Browser globals
|
|
root.WorldWind = factory();
|
|
}
|
|
}(this, function () {
|
|
|