Skip to content

[Svelte5] what is state_descriptors_fixed [ChatJs] #13689

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

Closed
Neptunium1129 opened this issue Oct 19, 2024 · 3 comments
Closed

[Svelte5] what is state_descriptors_fixed [ChatJs] #13689

Neptunium1129 opened this issue Oct 19, 2024 · 3 comments

Comments

@Neptunium1129
Copy link
Author

thanks..

https://svelte-5-preview.vercel.app/docs/runes#$state-snapshot

Thank you. I understand that Chart.js is highly reactive!

@destinyFvcker
Copy link

In the svelte5 documentation, it is recommended to use $effect rune instead of update/delete functions(there)

so i find a way to use it: svelte playground the key here is not pass $state as a param to action, instead, let the action capture it.Then just use $state.snapshot when passing $state into the Chart constructor.

But I don't know if this is the best practice! Please correct me if there is a better way to do it😂

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

3 participants