$ ./guess_the_languageProblem Solving — fill the blank
Problem Solving — fill the blank · medium · #152

Fill in the blank

// map then flatten one level
const tags = posts.____((p) => p.tags);

Answer: flatMap (also accepted: flatMap, flatMap())

flatMap() maps each item then flattens the result one level.
Play Problem Solving ▸