Fixed rsx emit with new AccessCell
This commit is contained in:
+9
-7
@@ -76,13 +76,15 @@ fn emit_node_scope(node: &RsxNode) -> TokenStream {
|
||||
{
|
||||
#deps_emit
|
||||
r.dynamic_scope(move |scope| {
|
||||
if #cond {
|
||||
if scope.children.lock().unwrap().is_empty() {
|
||||
#(#kids)*
|
||||
scope.access_children(|children| {
|
||||
if #cond {
|
||||
if children.is_empty() {
|
||||
#(#kids)*
|
||||
}
|
||||
} else {
|
||||
.children.clear();
|
||||
}
|
||||
} else {
|
||||
scope.children.lock().unwrap().clear();
|
||||
}
|
||||
})
|
||||
}, #deps_vec_emit);
|
||||
}
|
||||
}
|
||||
@@ -103,7 +105,7 @@ fn emit_node_scope(node: &RsxNode) -> TokenStream {
|
||||
#deps_emit
|
||||
#[allow(unused_parens)]
|
||||
r.dynamic_scope(move |scope| {
|
||||
scope.children.lock().unwrap().clear();
|
||||
scope.access_children(|children| children.clear());
|
||||
for #pat in #expr {
|
||||
#(#kids)*
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user