mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-05-30 14:31:02 +00:00
1 line
2.4 KiB
Plaintext
1 line
2.4 KiB
Plaintext
{"dependencies":[],"output":[{"data":{"code":"__d(function (global, require, _$$_IMPORT_DEFAULT, _$$_IMPORT_ALL, module, exports, _dependencyMap) {\n \"use strict\";\n\n Object.defineProperty(exports, '__esModule', {\n value: true\n });\n exports.arrayShuffle = arrayShuffle;\n /**\n * @name arrayShuffle\n * @description Shuffles the input array (unlike sort, this is not done in-place)\n */\n function arrayShuffle(input) {\n const result = input.slice();\n let curr = result.length;\n // noop for the single entry\n if (curr === 1) {\n return result;\n }\n while (curr !== 0) {\n // ~~ is more performant than Math.floor\n const rand = ~~(Math.random() * curr);\n curr--;\n [result[curr], result[rand]] = [result[rand], result[curr]];\n }\n return result;\n }\n});","lineCount":27,"map":[[7,2,5,0,"exports"],[7,9,5,0],[7,10,5,0,"arrayShuffle"],[7,22,5,0],[7,25,5,0,"arrayShuffle"],[7,37,5,0],[8,2,1,0],[9,0,2,0],[10,0,3,0],[11,0,4,0],[12,2,5,7],[12,11,5,16,"arrayShuffle"],[12,23,5,28,"arrayShuffle"],[12,24,5,29,"input"],[12,29,5,34],[12,31,5,36],[13,4,6,4],[13,10,6,10,"result"],[13,16,6,16],[13,19,6,19,"input"],[13,24,6,24],[13,25,6,25,"slice"],[13,30,6,30],[13,31,6,31],[13,32,6,32],[14,4,7,4],[14,8,7,8,"curr"],[14,12,7,12],[14,15,7,15,"result"],[14,21,7,21],[14,22,7,22,"length"],[14,28,7,28],[15,4,8,4],[16,4,9,4],[16,8,9,8,"curr"],[16,12,9,12],[16,17,9,17],[16,18,9,18],[16,20,9,20],[17,6,10,8],[17,13,10,15,"result"],[17,19,10,21],[18,4,11,4],[19,4,12,4],[19,11,12,11,"curr"],[19,15,12,15],[19,20,12,20],[19,21,12,21],[19,23,12,23],[20,6,13,8],[21,6,14,8],[21,12,14,14,"rand"],[21,16,14,18],[21,19,14,21],[21,20,14,22],[21,22,14,24,"Math"],[21,26,14,28],[21,27,14,29,"random"],[21,33,14,35],[21,34,14,36],[21,35,14,37],[21,38,14,40,"curr"],[21,42,14,44],[21,43,14,45],[22,6,15,8,"curr"],[22,10,15,12],[22,12,15,14],[23,6,16,8],[23,7,16,9,"result"],[23,13,16,15],[23,14,16,16,"curr"],[23,18,16,20],[23,19,16,21],[23,21,16,23,"result"],[23,27,16,29],[23,28,16,30,"rand"],[23,32,16,34],[23,33,16,35],[23,34,16,36],[23,37,16,39],[23,38,16,40,"result"],[23,44,16,46],[23,45,16,47,"rand"],[23,49,16,51],[23,50,16,52],[23,52,16,54,"result"],[23,58,16,60],[23,59,16,61,"curr"],[23,63,16,65],[23,64,16,66],[23,65,16,67],[24,4,17,4],[25,4,18,4],[25,11,18,11,"result"],[25,17,18,17],[26,2,19,0],[27,0,19,1],[27,3]],"functionMap":{"names":["<global>","arrayShuffle"],"mappings":"AAA;OCI;CDc"},"hasCjsExports":false},"type":"js/module"}]} |