improved documentation and refactored naming to be more self-explanatory
This commit is contained in:
1 parent
e4d60c8dfc
commit
adfbb6c380
91 files changed
+1663
-1553
No files matched your search
@@ -100,14 +100,15 @@ fn memos_prevents_component_rerun() {
|
||||
let signal = cx.props.signal;
|
||||
counter.borrow_mut().component += 1;
|
||||
|
||||
let memo = cx.use_hook(move || {
|
||||
to_owned![counter];
|
||||
selector(move || {
|
||||
counter.borrow_mut().effect += 1;
|
||||
println!("Signal: {:?}", signal);
|
||||
signal.value()
|
||||
})
|
||||
});
|
||||
let memo =
|
||||
cx.use_hook(move || {
|
||||
to_owned![counter];
|
||||
selector(move || {
|
||||
counter.borrow_mut().effect += 1;
|
||||
println!("Signal: {:?}", signal);
|
||||
signal.value()
|
||||
})
|
||||
});
|
||||
match cx.generation() {
|
||||
0 => {
|
||||
assert_eq!(memo.value(), 0);
|
||||
|
||||
Reference in new issue
Block a user