11#ifndef CWIST_HTML_COMPONENT_H
12#define CWIST_HTML_COMPONENT_H
HTML element builder and renderer.
void cwist_html_component_destroy(cwist_html_component_t *comp)
Destroy a component. Elements it already produced are unaffected.
cwist_html_component_t * cwist_html_component_create(const char *name, cwist_html_component_render_fn render_fn)
Create a component.
cwist_html_element_t *(* cwist_html_component_render_fn)(const void *props, cwist_html_element_t **children, size_t child_count)
Render callback for a component.
struct cwist_html_component cwist_html_component_t
cwist_html_element_t * cwist_html_component_instantiate(cwist_html_component_t *comp, const void *props, cwist_html_element_t **children, size_t child_count)
Render one instance of a component.
const char * cwist_html_component_name(const cwist_html_component_t *comp)
Return the name the component was created with.