HTML
Render an HTML tag with optional raw HTML text inside.
@solara.component
def HTML(tag="div", unsafe_innerHTML=None, style: str = None, classes: List[str] = [], attributes=None, class_: str = None):
...
Arguments
tag
: HTML tag name for the top level element (default:div
)unsafe_innerHTML
: HTML string to be rendered inside the tag. Note that this is not sanitized, so be careful this cannot include JavaScript from user input!style
: CSS style string to be applied to the top level element.classes
: List of CSS classes to be applied to the top level element.attributes
: Dictionary of attributes to be applied to the top level element.class_
: (deprecated) CSS class to be applied to the top level element.
Example
Custom html
- Item 1
- Item 2