Prism · Arrays
$flatten
Flattens an array of arrays by one level. An element that is not an array is kept as it is.
{ nested: [[1, 2], [3], 4, [5, [6]]] }{ $flatten: { $ref: '$.nested' } }[1, 2, 3, 4, 5, [6]]
Runs in this page on the installed package. The input and the expected output are defined by the example.