Might seem like a bug, it's a feature instead. The explanation goes down to... javascript! As simple as that!
We're so used to javascript frameworks doing all sort of things that we forget that displaying the value of a javascript variable in the DOM has to be explicitly done, it's not a default js behaviour.
When you want to push the performance and optimize your code, it makes sense to avoid doing it all the time if it's not necessary and that's what most of the js form libraries are doing: preventing unnecessary rerenders.
They also all provide a simple and straightforward API to subscribe and react on changes for you to be used consciously.
Watch the full playlist: • TanStack Form Tutorial
Source code: https://github.com/Balastrong/tanstac... ⭐️
_______________________________
Support my work: https://github.com/sponsors/Balastrong
Hit like and subscribe for more content! :D
Beginner-Friendly Open Source Projects: https://github.com/DevLeonardoCommunity
Join the Discord community! Here's the invite: / discord
You can also follow me on the other platforms:
Twitter: / balastrong
dev.to: https://dev.to/balastrong
GitHub: https://github.com/Balastrong
Home: https://leonardomontini.dev/
TikTok: / balastrong
Instagram: / devbalastrong
_______________________________
TIMESTAMPS
00:00 Overview
00:14 Render an Array
01:29 Read values
02:06 Add elements
03:02 Remove elements
03:33 Array of Objects
05:18 Change order of items
#tanstack #reactjs #form
Смотрите видео Why values on my React form do not update? онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Dev Leonardo 27 Август 2024, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 323 раз и оно понравилось 9 людям.