3 ms·
On mobile the homepages animated "an individual contributor role." text overflows with the button placement. Also when typing in a filter for the location name
by stevewodil 7y ago
On mobile the homepages animated "an individual contributor role." text overflows with the button placement.
Also when typing in a filter for the location name, the site stutters. This is probably because the JS is trying to filter the whole list on each keypress. You could implement a slight delay before starting a search. I've previously implemented something similar by restarting a timer (clearTimeout + setTimeout) each keypress. Once the setTimeout actually executes (in my case after 200 ms) OR the user hits the enter key, the state is updated and the filter search is performed using the current value of the text input. I've found this to be a great solution for responsiveness.
- krazykonkani 7y agoMobile needs a lot of love for sure. Thanks for suggesting the solution for speeding up the search field, we have an item in this week's list to fix it!
- leesalminen 7y agoLodash.js has a great `_.throttle()` that I use all the time to buffer keypress/state management.
- stevewodil 7y agothrottle uses debounce, which uses a timer + setTimeout and clearTimeout :)
- krazykonkani 7y agoWe tried your suggestion, worked great. Its live now, thanks again!
- stevewodil 7y agoAwesome! Good luck with everything