Skip to content

fix: autoscroll reactivity #329

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

Merged
merged 1 commit into from
Jul 2, 2024

Conversation

johann-crabnebula
Copy link
Contributor

Solid seems to optimize the if statement in the createEffect call, in this case it breaks reactivity for me :/

I rewrote the code to work around this.

…not work without the observed props being above the if
Copy link

netlify bot commented Jul 2, 2024

Deploy Preview for cn-devtools-app ready!

Name Link
🔨 Latest commit f2eed59
🔍 Latest deploy log https://app.netlify.com/sites/cn-devtools-app/deploys/66836912c4cecc000898d237
😎 Deploy Preview https://deploy-preview-329--cn-devtools-app.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@alex-crabnebula
Copy link
Contributor

What happened is that you put a non-reactive property before the reactive properties, so if the former is false, the effect never subscribes to the latter.

@johann-crabnebula johann-crabnebula merged commit 5f84d1e into main Jul 2, 2024
6 checks passed
@johann-crabnebula johann-crabnebula deleted the fix/autoscroll-solid-optimization-issue branch July 2, 2024 11:02
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

Successfully merging this pull request may close these issues.

3 participants