javascript-library
Version:
POC for npm package publishing and deploy
276 lines (251 loc) • 6.31 kB
JavaScript
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
else if(typeof define === 'function' && define.amd)
define([], factory);
else if(typeof exports === 'object')
exports["javascript-library"] = factory();
else
root["javascript-library"] = factory();
})(this, function() {
return /******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])
/******/ return installedModules[moduleId].exports;
/******/
/******/ // Create a new module (and put it into the cache)
/******/ var module = installedModules[moduleId] = {
/******/ i: moduleId,
/******/ l: false,
/******/ exports: {}
/******/ };
/******/
/******/ // Execute the module function
/******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
/******/
/******/ // Flag the module as loaded
/******/ module.l = true;
/******/
/******/ // Return the exports of the module
/******/ return module.exports;
/******/ }
/******/
/******/
/******/ // expose the modules object (__webpack_modules__)
/******/ __webpack_require__.m = modules;
/******/
/******/ // expose the module cache
/******/ __webpack_require__.c = installedModules;
/******/
/******/ // identity function for calling harmony imports with the correct context
/******/ __webpack_require__.i = function(value) { return value; };
/******/
/******/ // define getter function for harmony exports
/******/ __webpack_require__.d = function(exports, name, getter) {
/******/ if(!__webpack_require__.o(exports, name)) {
/******/ Object.defineProperty(exports, name, {
/******/ configurable: false,
/******/ enumerable: true,
/******/ get: getter
/******/ });
/******/ }
/******/ };
/******/
/******/ // getDefaultExport function for compatibility with non-harmony modules
/******/ __webpack_require__.n = function(module) {
/******/ var getter = module && module.__esModule ?
/******/ function getDefault() { return module['default']; } :
/******/ function getModuleExports() { return module; };
/******/ __webpack_require__.d(getter, 'a', getter);
/******/ return getter;
/******/ };
/******/
/******/ // Object.prototype.hasOwnProperty.call
/******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
/******/
/******/ // __webpack_public_path__
/******/ __webpack_require__.p = "";
/******/
/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 3);
/******/ })
/************************************************************************/
/******/ ([
/* 0 */
/***/ (function(module, exports) {
module.exports = [
"Beta test",
"New Name",
"4-LOM",
"Aayla Secura",
"Admiral Ackbar",
"Admiral Thrawn",
"Ahsoka Tano",
"Anakin Solo",
"Asajj Ventress",
"Aurra Sing",
"Senator Bail Organa",
"Barriss Offee",
"Bastila Shan",
"Ben Skywalker",
"Bib Fortuna",
"Biggs Darklighter",
"Boba Fett",
"Bossk",
"Brakiss",
"C-3PO",
"Cad Bane",
"Cade Skywalker",
"Callista Ming",
"Captain Rex",
"Carnor Jax",
"Chewbacca",
"Clone Commander Cody",
"Count Dooku",
"Darth Bane",
"Darth Krayt",
"Darth Maul",
"Darth Nihilus",
"Darth Vader",
"Dash Rendar",
"Dengar",
"Durge",
"Emperor Palpatine",
"Exar Kun",
"Galen Marek",
"General Crix Madine",
"General Dodonna",
"General Grievous",
"General Veers",
"Gilad Pellaeon",
"Grand Moff Tarkin",
"Greedo",
"Han Solo",
"IG 88",
"Jabba The Hutt",
"Jacen Solo",
"Jaina Solo",
"Jango Fett",
"Jarael",
"Jerec",
"Joruus C'Baoth",
"Ki-Adi-Mundi",
"Kir Kanos",
"Kit Fisto",
"Kyle Katarn",
"Kyp Durron",
"Lando Calrissian",
"Luke Skywalker",
"Luminara Unduli",
"Lumiya",
"Mace Windu",
"Mara Jade",
"Mission Vao",
"Natasi Daala",
"Nom Anor",
"Obi-Wan Kenobi",
"Padmé Amidala",
"Plo Koon",
"Pre Vizsla",
"Prince Xizor",
"Princess Leia",
"PROXY",
"Qui-Gon Jinn",
"Quinlan Vos",
"R2-D2",
"Rahm Kota",
"Revan",
"Satele Shan",
"Savage Opress",
"Sebulba",
"Shaak Ti",
"Shmi Skywalker",
"Talon Karrde",
"Ulic Qel-Droma",
"Visas Marr",
"Watto",
"Wedge Antilles",
"Yoda",
"Zam Wesell",
"Zayne Carrick",
"Zuckuss"
];
/***/ }),
/* 1 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var uniqueRandom = __webpack_require__(2);
module.exports = function (arr) {
var rand = uniqueRandom(0, arr.length - 1);
return function () {
return arr[rand()];
};
};
/***/ }),
/* 2 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
module.exports = function (min, max) {
var prev;
return function rand() {
var num = Math.floor(Math.random() * (max - min + 1) + min);
return prev = num === prev && min !== max ? rand() : num;
};
};
/***/ }),
/* 3 */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
var _starwarsNames = __webpack_require__(0);
var _starwarsNames2 = _interopRequireDefault(_starwarsNames);
var _uniqueRandomArray = __webpack_require__(1);
var _uniqueRandomArray2 = _interopRequireDefault(_uniqueRandomArray);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
/**
* Created by jonlazarini on 03/02/17.
*/
var getRandomItem = (0, _uniqueRandomArray2.default)(_starwarsNames2.default);
// Commonjs
/**
*
* @type {{all, random: random}}
*/
module.exports = {
all: _starwarsNames2.default,
random: random
};
/**
*
* @param number
* @returns {Array}
*/
function random(number) {
if (number === undefined) {
return getRandomItem();
} else {
var randomItems = [];
for (var i = 0; i < number; i++) {
randomItems.push(getRandomItem());
}
return randomItems;
}
}
// // check code coverage - debug purpose only
// function debugIstanbul() {
// console.log('debug');
// }
/**
Node REPL
`node`
require module and test exports
*/
/***/ })
/******/ ]);
});
//# sourceMappingURL=index.umd.js.map