etc/browser-demo/src/index.js
function render({ document }) {
  console.debug("rendering");
  document.querySelectorAll(".replace-with-pubcontrol").forEach(el => {
    el.innerHTML = `
    <div>
      <h2>pubcontrol default export</h2>
      <pre>${JSON.stringify(objectSchema(PubControl), null, 2)}</pre>
    </div>
    `;
  });
}
function render({ document }) {
  console.debug("rendering");
  document.querySelectorAll(".replace-with-pubcontrol").forEach(el => {
    el.innerHTML = `
    <div>
      <h2>pubcontrol default export</h2>
      <pre>${JSON.stringify(objectSchema(PubControl), null, 2)}</pre>
    </div>
    `;
  });
}
function render ( { document } ) { console . debug ( "rendering" ) ; document . querySelectorAll ( ".replace-with-pubcontrol" ) . forEach ( el => { el . innerHTML = ` ${ JSON . stringify ( objectSchema ( PubControl ) , null , 2 ) } ` ; } ) ; }
Render a message showing off pubcontrol.
Show it wherever the html has opted into replacement.
Render a message showing off pubcontrol . Show it wherever the html has opted into replacement .