You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
611 B
28 lines
611 B
"use strict"; |
|
|
|
exports.__esModule = true; |
|
exports.default = void 0; |
|
|
|
var _one = _interopRequireDefault(require("./one")); |
|
|
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } |
|
|
|
/* Transform the children of `parent`. */ |
|
function all(h, parent) { |
|
const nodes = parent.children || []; |
|
const { |
|
length |
|
} = nodes; |
|
const values = []; |
|
let index = -1; |
|
|
|
while (++index < length) { |
|
const result = (0, _one.default)(h, nodes[index], parent); |
|
values.push(result); |
|
} |
|
|
|
return values.filter(node => node); |
|
} |
|
|
|
var _default = all; |
|
exports.default = _default; |