Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Popover causing error #382

Closed
glennpierce opened this issue Feb 20, 2025 · 2 comments
Closed

Popover causing error #382

glennpierce opened this issue Feb 20, 2025 · 2 comments

Comments

@glennpierce
Copy link

When I have a Popover in a scrobbale section

If I click on the item to display the popup and then scroll I see the error

thaw-0.4.2/src/popover/mod.rs:140:21) outside a reactive tracking context. This might mean your app is not responding to changes in signal values in the way you expect.

Here’s how to fix it:

1. If this is inside a `view!` macro, make sure you are passing a function, not a value.
  ❌ NO  <p>{x.get() * 2}</p>
  ✅ YES <p>{move || x.get() * 2}</p>

2. If it’s in the body of a component, try wrapping this access in a closure: 
  ❌ NO  let y = x.get() * 2
  ✅ YES let y = move || x.get() * 2.

3. If you’re *trying* to access the value without tracking, use `.get_untracked()` or `.with_untracked()` instead.
@luoxiaozero
Copy link
Collaborator

luoxiaozero commented Feb 21, 2025

Can you try the fix/binder-node-ref-tracking branch to see if it solves the problem?

@glennpierce
Copy link
Author

glennpierce commented Feb 22, 2025

Yep that fixes it

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants