MMOframework
Pourquoi l'IA Playground Bibliothèques Documentation Rechercher Agence
FR EN
Index

mmo-doc-example

1 symbole · générée le 27 Oct 2026

element

mmo-doc-example

mmo-doc-example.jhs:1

A runnable @example block. Displays the PHP snippet (via <mmo-code>) read from its own data-code attribute, and on "Run" POSTs only {symbol, index} to the server (ExampleController) -- the actual source code is never sent by the client, only re-read server-side from that symbol's own doc comment, then executed in a sandboxed subprocess (ExampleRunner).

<mmo-doc-example></mmo-doc-example>
Étend
CustomShadowElement

Index

init()
showCode()Rebuilds the code snippet from data-code (a JSON-encoded string, so embedded newlines survive) via the DOM API -- never through innerHTML.
runExample()Sends {symbol, index} to the run endpoint and shows stdout/stderr.

Méthodes3

showCode()

mmo-doc-example.jhs:29

Rebuilds the code snippet from data-code (a JSON-encoded string, so embedded newlines survive) via the DOM API -- never through innerHTML.

showCode()

runExample()

mmo-doc-example.jhs:40

Sends {symbol, index} to the run endpoint and shows stdout/stderr. Never sends code.

runExample()