preview

Live previews for AnswerUI's HTML foundation notebooks.

Preview

def Preview(
    markup, frame
):

preview

def preview(
    markup, # HTML to render
    *, css=None, # Replacement stylesheet; None uses the distributed AnswerUI CSS
    js:str='', # Inline module for a live example
    width:str='100%', # Frame width as a CSS length
    height=None, # Fixed height as a CSS length; None fits the content
):

Show an isolated, replayable HTML example. Store its markup in the notebook.