1 | "use strict";
|
2 | Object.defineProperty(exports, "__esModule", { value: true });
|
3 | exports.arrayToString = void 0;
|
4 |
|
5 |
|
6 |
|
7 | const arrayToString = (array, space, next) => {
|
8 |
|
9 | const values = array
|
10 | .map(function (value, index) {
|
11 | const result = next(value, index);
|
12 | if (result === undefined)
|
13 | return String(result);
|
14 | return space + result.split("\n").join(`\n${space}`);
|
15 | })
|
16 | .join(space ? ",\n" : ",");
|
17 | const eol = space && values ? "\n" : "";
|
18 | return `[${eol}${values}${eol}]`;
|
19 | };
|
20 | exports.arrayToString = arrayToString;
|
21 |
|
\ | No newline at end of file |