create project
This commit is contained in:
25
kitabcitab/node_modules/next/dist/shared/lib/flatten.js
generated
vendored
Normal file
25
kitabcitab/node_modules/next/dist/shared/lib/flatten.js
generated
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.flatten = flatten;
|
||||
function flatten(list) {
|
||||
let jlen, j, value, idx = 0, result = [];
|
||||
while(idx < list.length){
|
||||
if (Array.isArray(list[idx])) {
|
||||
value = flatten(list[idx]);
|
||||
j = 0;
|
||||
jlen = value.length;
|
||||
while(j < jlen){
|
||||
result[result.length] = value[j];
|
||||
j += 1;
|
||||
}
|
||||
} else {
|
||||
result[result.length] = list[idx];
|
||||
}
|
||||
idx += 1;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
//# sourceMappingURL=flatten.js.map
|
||||
Reference in New Issue
Block a user