How can I expose BackendNodeId in the a11y snapshot?

Puppeteer

BackendNodeId is exposed in the a11y snapshot. Each node in the snapshot includes a backendNodeId that lets you map accessibility nodes to their corresponding DOM nodes. Example:

const snapshot = await page.accessibility.snapshot({ interestingOnly: false });
console.log(snapshot.nodes[0].backendNodeId);