Function sauron::prelude::html_element [−][src]
pub fn html_element<MSG>(
tag: &'static str,
attrs: Vec<Attribute<&'static str, &'static str, AttributeValue<MSG>>, Global>,
children: Vec<Node<&'static str, &'static str, &'static str, AttributeValue<MSG>>, Global>
) -> Node<&'static str, &'static str, &'static str, AttributeValue<MSG>>
Expand description
Creates an html element
Examples
use sauron::prelude::*;
let container:Node<()> = html_element("div", vec![class("container")], vec![]);
assert_eq!(node!{<div class="container"></div>},container);