wp-includes/html-api/class-wp-html-active-formatting-elements.php:171$html = '<em><strong><a>We are here';
foreach ( $stack->walk_down() as $node ) {
echo "{$node->node_name} -> ";
}
> EM -> STRONG -> A -> To start with the most-recently added element and walk towards the top, see WP_HTML_Active_Formatting_Elements::walk_up(). public function walk_down() { $count = count( $this->stack ); for ( $i = 0; $i < $count; $i++ ) { yield $this->stack[ $i ]; } }Introduced in 6.4.0. Unchanged from 6.7.7 through 7.1.0.
Signature, return type and hooks compared across 5 parsed releases.
src/wp-includes/html-api/class-wp-html-active-formatting-elements.php, and regenerated for each WordPress release so it tracks the code rather than a snapshot of it.