flatNodes
Returns every mark among a node's children with the cue wrappers unwrapped, whether or not a given mark is on screen yet.
@internote/canvas-sdkOn this page
import { flatNodes } from '@internote/canvas-sdk';What anything that needs to see the whole picture reads: the frame deciding its domains, the footer listing what is there, the walk that collects an environment's free letters. For the marks a reader can see right now, use visibleNodes.
#Signature
<N extends NodeLike>(children: readonly N[]): N[]#Parameters
childrenAn environment's children, as
childNodes returns them.#Returns
The marks in source order, with every cue's contents in its place.
#Example
const points = flatNodes(childNodes(ctx.node.body)).filter((node) => node.identifier === 'point');Declared in packages/canvas-sdk/src/environment/nodes.ts:125.