Skip to content

Commit

Permalink
Update docs
Browse files Browse the repository at this point in the history
  • Loading branch information
hamza1311 committed Aug 28, 2022
1 parent af33209 commit 07dbcf1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 9 deletions.
2 changes: 2 additions & 0 deletions packages/yew/src/dom_bundle/traits.rs
Expand Up @@ -32,6 +32,8 @@ pub(super) trait Reconcilable {
/// - `next_sibling`: to find where to put the node.
///
/// Returns a reference to the newly inserted element.
/// The [`NodeRef`] points the first element (if there are multiple nodes created),
/// or is the passed in next_sibling if there are no element is created.
fn attach(
self,

Expand Down
11 changes: 2 additions & 9 deletions packages/yew/src/virtual_dom/vnode.rs
Expand Up @@ -60,22 +60,15 @@ impl VNode {
/// In the browser, this function creates an element, sets the passed HTML to its `innerHTML`
/// and inserts the contents of it into the DOM.
///
/// If there are multiple elements, they're wrapped in a `div`. If this behavior is not desired,
/// ensure there is only one top level node.
///
/// # Behavior on server
///
/// When rendering on the server, the contents of HTML are directly injected into the HTML
/// stream.
///
/// ## Warning
///
/// The contents are **not** sanitized. You, as the developer, are responsible to
/// ensure the HTML string passed to this method not malicious
///
/// ## Panics
///
/// If the HTML string is invalid, the [`ServerRenderer`](crate::ServerRenderer) will panic
/// The contents are **not** sanitized or validated. You, as the developer, are responsible to
/// ensure the HTML string passed to this method are _valid_ and _not malicious_
///
/// # Example
///
Expand Down

0 comments on commit 07dbcf1

Please sign in to comment.