0
https://codepen.io/leongaban/pen/EgvBpxWarum ist mein R.flatten (R.map (R.prop Rückkehr und undefiniert Objekt hier? RamdaJS
Wie ich es verstehe, ich bin in meinem comboTags Array gerade vorbei. Die Daten immer in curried ist die rechte Seite eines Ramda Aussage.
ich flatTags
bin erwartet ein Array von tag1
und tag2
enthalten
const comboTags = [
{
tags: [
{
name: 'tag1'
}
],
person: {
name: 'Jerry'
}
},
{
tags: [
{
name: 'tag2'
}
],
person: {
name: 'Laura'
}
}
];
const flattenTags = container => R.flatten(R.map(R.prop('tags')));
let flatTags = flattenTags(comboTags);
console.log('flatTags',flatTags);