Skip to main content

remove

Function remove 

Source
pub fn remove(id: &str) -> String
Expand description

Builds a message that removes the element with id id from the page (htmx delete).

id is escaped.

ยงExamples

assert_eq!(ocre::realtime::remove("post_3"), "<div id=\"post_3\" hx-swap-oob=\"delete\"></div>");