CodePen Prefill Embeds API
Declarative embed API that transforms existing code blocks on a web page into live, interactive CodePen sandboxes without requiring users to navigate away. Code is supplied via data-prefill JSON attributes and pre elements; the embed script at public.codepenassets.com renders an isolated iFrame. Supports HTML, CSS, and JavaScript preprocessors, external stylesheets and scripts, and optional editable mode.