Skip to content

Instantly share code, notes, and snippets.

@shannonmoeller
Last active February 11, 2024 23:04
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shannonmoeller/280dda1f47e222c1ee88e5613bd01897 to your computer and use it in GitHub Desktop.
Save shannonmoeller/280dda1f47e222c1ee88e5613bd01897 to your computer and use it in GitHub Desktop.
Rollup code-splitting outputs.
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('./shared'), exports) :
typeof define === 'function' && define.amd ? define(['./shared', 'exports'], factory) :
(factory((global.shared, global.a = global.a || {})));
}(this, (function (shared, exports) { 'use strict';
const foo = shared.foo;
function bar() {
return 'bar';
}
function a() {
return foo() + bar();
}
exports.a = a;
Object.defineProperty(exports, '__esModule', { value: true });
});
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('./shared'), exports) :
typeof define === 'function' && define.amd ? define(['./shared', 'exports'], factory) :
(factory((global.shared, global.b = global.b || {})));
}(this, (function (shared, exports) { 'use strict';
const foo = shared.foo;
function baz() {
return 'baz';
}
function b() {
return foo() + baz();
}
exports.b = b;
Object.defineProperty(exports, '__esModule', { value: true });
});
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
typeof define === 'function' && define.amd ? define(['exports'], factory) :
(factory((global.shared = global.shared || {})));
}(this, (function (exports) { 'use strict';
function foo() {
return 'foo';
}
exports.foo = foo;
Object.defineProperty(exports, '__esModule', { value: true });
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment