Search over multiple columns in Supabase freezes tab

  • plusmin-1347508089318019156

    Armand

    8 days ago

    I've set up a GET request in the toddle API to search with a string over multiple columns in a Supabase table. And I got it to work, just after playing a bit with the search (changing search string, removing search string, adding new, etc) it always freezes the tab.

    This happens on different browsers and also when testing on mobile.

    I have set up the autofetch to only be true when the search variable has a size greater or equal to 2.

    See below how I've set up the API. I've used the Supabase docs to figure out how to query parameters and the fact that I get correct results when I do a search makes me think the issue is not there.
    1347508089804423178-Screenshot_2025-03-07_at_16.47.45.png
    1347508090110476338-Screenshot_2025-03-07_at_16.44.46.png
    1347508090731368458-Screenshot_2025-03-07_at_16.44.25.png
    1
  • plusmin-1348559810400096280

    Armand

    5 days ago

    I found the cause. I had so-accordion as a wrapper of li. I did a Lighthouse test and this was one of things it found: "not al elements in the ul are li"

    Once I changed that it made all the difference.

    I don't know if this is related to the Spark Core package (that the so-accordion component makes use of), but probably best to follow best practices and only have li in ul.
    1348559810295107594-Screenshot_2025-03-10_at_14.30.31.png
  • (screenshot is of how it is now - solved)
  • max.kayr-1348563029239009303

    Max

    5 days ago

    Hi Armand! Yeah, that is a limitation of toddle and therefore Spark Core. We cannot change the tags dynamically... But is weird that this froze your tab... Are you sure that this was the cause?
  • plusmin-1348563552755126295

    Armand

    5 days ago

    It is the only thing I changed. And once I changed it it worked immediately (tested on Safari, Firefox and iOS Safari). Like night and day difference.
  • plusmin-1348564024320725042

    Armand

    5 days ago

    Only thing to note is that when I originally posted this (on Friday) it would always freeze the tab completely. I could not even close the tab. When I tried to close the tab it would only close after 2mins or so.
    But today it would just lag for 10sec or so (prior to changing the li)
  • Tod-1348564025755041943

    Tod

    5 days ago

    Great energy @Armand! Your continuous contribution to the toddle Community just made you advance to Community Level 12!

Stop scrolling. Start building.

toddle is a visual web app builder that rivals custom code — but accessible to your entire team!

Try toddle — it's free!

© Copyright 2024 toddle. All rights reserved.