HOTFIX: OrderCatalog scroll To Item #1026
Labels
No Milestone
No Assignees
3 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: verdnatura/salix-front#1026
Loading…
Reference in New Issue
No description provided.
Delete Branch "hotfix_scrollToItem"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Después de añadir un producto, se refresca y pierde el scroll
fix: hotfix_scrollToItemto HOTFIX: OrderCatalog scroll To Item@ -79,0 +83,4 @@
const scrollToItem = async (id) => {
await nextTick();
setTimeout(() => {
Y si lo tuviese que cargar tardase 101ms ya no iria?
Le puse el nextTick para que el DOM terminase de montarse pero no terminaba de funcionar
Con el setTimeout conseguí el efecto deseado
Iría de todas maneras porque el timeout no depende de la petición anterior
https://chatgpt.com/c/675000bd-53e8-8011-8a7a-0481f274180d
Resuelto con requestAnimationFrame
He usado un console.error y solo se muestra 1 vez