Search Filter in React JS - Filter Through Results

แชร์
ฝัง
  • เผยแพร่เมื่อ 7 พ.ย. 2024

ความคิดเห็น • 214

  • @sebastianlozano7707
    @sebastianlozano7707 ปีที่แล้ว +11

    Literally I watched 5 other videos trying to understand how to render the list filtering the data and they made it look so difficult! You were way clearer my friend! Thanks so much!

  • @juanxc7
    @juanxc7 11 หลายเดือนก่อน +30

    my bro here just accomplished what I've been struggling with for a whole month in 8 minutes what a pro

    • @kattagurunadham9425
      @kattagurunadham9425 หลายเดือนก่อน

      hlo bro iam not getting the searchbar bro

  • @RealParadox85
    @RealParadox85 3 หลายเดือนก่อน

    EXTREMELY clear and easy to follow video and I am someone who has used React since 2018. Well done, sir.

  • @josephomotade864
    @josephomotade864 2 ปีที่แล้ว +6

    You are behind my success with react and being a web developer.
    Thanks again bro.

  • @marcelooliveira5034
    @marcelooliveira5034 ปีที่แล้ว +12

    thank you so much for this! really helpful and straightforward. exactly what I needed for a project!

  • @benrenny9828
    @benrenny9828 2 ปีที่แล้ว +10

    Hey Colin I'm grateful for your content. Keeps improving my js skills. Please a typescript tutorial will come in handy

    • @codecommerce
      @codecommerce  2 ปีที่แล้ว +3

      Thank you dude! Typescript coming soon

  • @nanakwekuotoo1775
    @nanakwekuotoo1775 2 ปีที่แล้ว +10

    I don't know how you're being slept on.
    You're my best react teacher on here💯

  • @mediumsofy
    @mediumsofy 4 หลายเดือนก่อน

    Thank you so much man, I was struggling trying to figure out how to implement this feature in my graduation project and your video made it all clear, you're a great teacher!

  • @FootballForThePeople
    @FootballForThePeople 2 ปีที่แล้ว

    Best Coding Tutorial Voice I have encountered so far.

  • @itbeat7899
    @itbeat7899 ปีที่แล้ว

    this just solved the problem I had for the last 8 months. Thank you so so much! you dont know how much I appreciate this help

  • @v.i.n.i.t968
    @v.i.n.i.t968 3 หลายเดือนก่อน

    i was thinking about create api for search user and use of map() to display it. You have saved our valuable time. Appriciated !!!

  • @anoopk.s1255
    @anoopk.s1255 ปีที่แล้ว +1

    I Check so many videos but don't understand.this video so comfortable and understand ❤ thanku

    • @codecommerce
      @codecommerce  ปีที่แล้ว

      Thank you- much appreciated!

  • @vibhashanaranhinda3774
    @vibhashanaranhinda3774 ปีที่แล้ว +4

    The most simplest and easy to understand tutorial. Keep making awesome tutorials like this.

  • @robbobpirate3678
    @robbobpirate3678 ปีที่แล้ว +2

    that .includes() is a game changer thanks for the knowledge

  • @the-boss-98
    @the-boss-98 11 หลายเดือนก่อน +2

    Every video you make is so helpful

  • @Peugeot9X8
    @Peugeot9X8 8 หลายเดือนก่อน

    Wow literally took me 3 minutes to apply what shown on the video, great job¡

  • @thrainii7324
    @thrainii7324 ปีที่แล้ว

    I used this search method while developing my project, it was much better, you are great

  • @tomasburian6550
    @tomasburian6550 2 ปีที่แล้ว +1

    Good stuff that every beginner should know as searching through data is a vital part of many projects out there. Just to be sure, if I want to search according to various parameters, not just the first name, I'll chain the filter functions like you showed in the Filter Method video?

  • @santhoshn9769
    @santhoshn9769 ปีที่แล้ว +7

    I feel like very comfortable in search filter. after watching this

  • @matthewtang6806
    @matthewtang6806 ปีที่แล้ว +1

    Thank you for your tutorial! Would be pleased to know if i've seperated the SearchBar & CustomerTable, how can i access the search value of useState in SearchBar.jsx in CustomerTable filter( )?

  • @selfmadetool
    @selfmadetool 7 หลายเดือนก่อน

    Thank you, sir. I was able to incorporate filtering into my project within a few minutes.

  • @nicmantzivis8978
    @nicmantzivis8978 ปีที่แล้ว +1

    Wow, I wrote so much code to achieve the same result, well done and thank you for this solution 😁

  • @FootballForThePeople
    @FootballForThePeople 2 ปีที่แล้ว +2

    Hey. Yet again, great video. If I also want to filter by another param such as.. email. Syntax wise, how would you go about this - if we want to filter by not only name but more?

  • @moshabbir_hossain
    @moshabbir_hossain 5 หลายเดือนก่อน

    That's a great video. It's very helpful and easier way for filtering data from an api.

  • @arnabsarkar5245
    @arnabsarkar5245 ปีที่แล้ว

    One of the most easiest video I have ever seen

  • @bakinloye2398
    @bakinloye2398 ปีที่แล้ว

    Thank you very much for this concise and straightforward tutorial. its so easy to grasp

  • @Brendan_M_
    @Brendan_M_ ปีที่แล้ว +1

    Thank you, this is so much easier than sending to the backend to search.
    One note, I noticed it didn't work if there is an uppercase letter in the search bar so I made a small change to:
    "onChange={(e) => setSearch(e.target.value.toLowerCase())}" so it's now completely case insensitive.

    • @codecommerce
      @codecommerce  ปีที่แล้ว

      Awesome! Great way to do it with a small amount of results :)

  • @Deqike_Michael2
    @Deqike_Michael2 8 หลายเดือนก่อน

    gr8 video, but how about last name, email, phone searching? is it possible to search simultaneously whenever I typed once?

  • @darkjoyboy04
    @darkjoyboy04 ปีที่แล้ว

    Thanks your video made me to understand how filter really works!

  • @leonelpaez9358
    @leonelpaez9358 ปีที่แล้ว +1

    Great work mate, too easy!

  • @notappi3982
    @notappi3982 2 ปีที่แล้ว

    thanks that was a great little trick i did had an idead how to do it but u made it simpler for me. thanks a lot LOVE from INDIA

  • @LuisTal1ercio
    @LuisTal1ercio ปีที่แล้ว

    thanks for this video, easy and fast,
    greetings from Argentina

  • @monique2839
    @monique2839 2 ปีที่แล้ว

    Very succinct video! As always I enjoy your content. I'm excited for the typescript video!

  • @thirumalasettysaisatish1043
    @thirumalasettysaisatish1043 ปีที่แล้ว +1

    Thanks for the tutorial, Brilliant Video!

  • @kisshore3853
    @kisshore3853 ปีที่แล้ว

    Clean & Clear mate, thanks ❤

  • @joshigaming1971
    @joshigaming1971 2 หลายเดือนก่อน +1

    Wtf, I Knew Everything, But I couldn't Implement, That's Really Easy,I appreciate Your Work ,🎉
    .......Sorry For My Horrible English

  • @eliucastillo6976
    @eliucastillo6976 11 หลายเดือนก่อน

    just what i was looking for, thank you

  • @uniquedivya113
    @uniquedivya113 ปีที่แล้ว

    Really ur great.. i tried with many videos but ur videos awesome man

  • @slblackmamba
    @slblackmamba 10 หลายเดือนก่อน +1

    just simple and perfect. thanks

    • @codecommerce
      @codecommerce  9 หลายเดือนก่อน

      You're welcome!

  • @marcusaureliusregulus2833
    @marcusaureliusregulus2833 2 ปีที่แล้ว +1

    I am somewhat new and was just wondering, will this not be slow? Or is this the best way how it is done? Apart from server side fetching. Will it be ok with thousands of items?

  • @LizyDaRealtor
    @LizyDaRealtor 3 หลายเดือนก่อน

    Wow thank you, made my work super easy !!!

  • @chrisdizzle313
    @chrisdizzle313 5 หลายเดือนก่อน

    This is EXACTLY what I need to do!

  • @blazerdork3497
    @blazerdork3497 2 ปีที่แล้ว +2

    Hi Clint, can it also be done by using the react props?
    PS: another great video! can't wait for the next one :)

    • @codecommerce
      @codecommerce  2 ปีที่แล้ว +1

      Hi Blazer, I kept everything in the App component, but yes!

  • @shahidshafi1227
    @shahidshafi1227 2 ปีที่แล้ว

    It's much easier than I thought. I thought making a search filter would be complex. Thanks for sharing ❤.

    • @codecommerce
      @codecommerce  2 ปีที่แล้ว +1

      Debunking the complex stuff!! Thank you Shahid!

  • @coffee80119
    @coffee80119 ปีที่แล้ว +4

    Thanks for the tutorial, short and down to the point. Mockaroo also is a great tool to use i think.
    Can you do a tutorial on facets searching also in nextjs and firestore?

  • @rahulsaroj789
    @rahulsaroj789 10 หลายเดือนก่อน

    Thanks for the tutorial, and Could you please let me know how to modify it so that it able to make searches based on other parameters as well.

    • @rahulsaroj789
      @rahulsaroj789 10 หลายเดือนก่อน +1

      got it!, for those who have same question, just replace below code:
      Object.values(item).join('') with item.first_name
      then final code would be like:
      .filter((item) => {
      return search.toLowerCase() === ''
      ? item
      : Object.values(item).join('').toLowerCase().includes(search.toLowerCase());
      })

  • @Berlin-v6d
    @Berlin-v6d 11 หลายเดือนก่อน

    Very good Explanation! 👍

  • @webdev_am
    @webdev_am ปีที่แล้ว

    Can you make another additional video for this but with “denouncing” technique?

  • @jimmyopot1972
    @jimmyopot1972 ปีที่แล้ว

    Thanks a lot, indeed benefited. Nairobi, Kenya

  • @sidd_shaikh
    @sidd_shaikh 10 หลายเดือนก่อน

    Hey great video but what if the data is too large?

  • @Carla-ib4ue
    @Carla-ib4ue 2 ปีที่แล้ว

    Nice video. Mockaroo seems to be a great tool, gonna make my next project using it! Thanks!

    • @codecommerce
      @codecommerce  2 ปีที่แล้ว +1

      I use it all the time!

  • @lalagisaa
    @lalagisaa 2 ปีที่แล้ว

    Awesome as always 🔥🔥

    • @codecommerce
      @codecommerce  2 ปีที่แล้ว

      Thank you Christian! 🔥

  • @exploreeewithmegha-om6gb
    @exploreeewithmegha-om6gb 7 หลายเดือนก่อน

    can we use date filter like from range to range??

  • @ahmedoraiby3059
    @ahmedoraiby3059 4 หลายเดือนก่อน

    thanks so mush . but how make search relate to all columns not just first name ?

  • @nimethhr9806
    @nimethhr9806 ปีที่แล้ว +1

    Thank you very much just what i needed

  • @alensacipi5433
    @alensacipi5433 ปีที่แล้ว +1

    such a great video, thanks for this this was straight forward and just on point really great content, immediately subscribed!!
    I think at line 39: it is only missing a .toLowerCase() after search so the input is always right => .... .includes(search.toLowerCase( ))

  • @aasheesh6001
    @aasheesh6001 2 หลายเดือนก่อน

    Thanks i just forget about filte. thanks bro for the video.

  • @mostafaekbal7093
    @mostafaekbal7093 2 ปีที่แล้ว

    Thank you so much man, I've learned a lot from this video.

  • @emirdior
    @emirdior ปีที่แล้ว

    Brilliant video, thank you!

  • @AkyeampongKwekuPrince
    @AkyeampongKwekuPrince 6 หลายเดือนก่อน

    How did you convert the json data to normal object data inside the Vs code? struggling with that for days

  • @swifttechnology3801
    @swifttechnology3801 2 หลายเดือนก่อน +1

    Very nice 👍

  • @Hachirou_Genji
    @Hachirou_Genji ปีที่แล้ว

    thank you so much for this, I'm grateful for you

  • @alvinchristianto-p2d
    @alvinchristianto-p2d ปีที่แล้ว

    how about pagination? if we implement pagination, does it only filter the first 'n' data ?

  • @sadimridha5753
    @sadimridha5753 ปีที่แล้ว

    Your vedio made my life easy❤

  • @EmersonDiazG
    @EmersonDiazG 2 ปีที่แล้ว

    Thank you very much, it helped me a lot for a requirement

  • @judoScott
    @judoScott 9 หลายเดือนก่อน

    That was great! Thank you so much

  • @jordiverbeek4917
    @jordiverbeek4917 8 หลายเดือนก่อน

    i have a question, i want to have my search bar in my header but how do i pass the state from the header to the app.jsx?

  • @mohammadhossein94
    @mohammadhossein94 ปีที่แล้ว

    hey thanks for the video !
    but what if we want't that filter on email and phoneNumber too ? how should we say that ?

  • @eladbar1579
    @eladbar1579 2 ปีที่แล้ว

    Awesome content bro! 🔥

  • @sarkaran
    @sarkaran ปีที่แล้ว

    I wonder why after filter I can not use onCLick on filtered items,

  • @Luunaquedateluuna
    @Luunaquedateluuna หลายเดือนก่อน

    Oh God, it was so simple 🥲 Thanks!!!

  • @charulatha
    @charulatha ปีที่แล้ว

    I searched a search filter video for so long today only i got an awesome sause video man ,thanks for that 👏🔥🔥🔥

  • @DevOpsUIGamer
    @DevOpsUIGamer 10 หลายเดือนก่อน

    how to handle if my form in different component like input tag search bar is there in navbar component and my data is in product component?

  • @abhinavdhama3014
    @abhinavdhama3014 2 ปีที่แล้ว

    Thats nice bro. I am working on twitch clone and learning new new concepts

    • @codecommerce
      @codecommerce  2 ปีที่แล้ว +1

      That’s what it’s all about!

  • @respectgmechager8054
    @respectgmechager8054 ปีที่แล้ว

    Thanks a lot..u save lot of time ❤❤❤❤..love from India
    I subscribed u

  • @TheVedicWarrior
    @TheVedicWarrior ปีที่แล้ว

    Thank man it was so helpful and easy ❤

  • @vimz92
    @vimz92 ปีที่แล้ว +1

    Bro, Thank you so much. Subscribed

  • @arush6778
    @arush6778 ปีที่แล้ว

    Very helpful tutorial. Many thanks

  • @sulthanathallah4809
    @sulthanathallah4809 ปีที่แล้ว

    it's so helpful, thanks man

  • @redh4y
    @redh4y ปีที่แล้ว

    How can I have the same result considering that my search input is a separated component?

  • @totitoti7863
    @totitoti7863 ปีที่แล้ว

    Really helpful for my project. Thanks😁😁

  • @pnahar0847
    @pnahar0847 7 หลายเดือนก่อน

    just wanted to ask im on windows and vscode doesn't autoformats code in js when i save the data what do i need to do?

  • @LeaNahuelMartinez
    @LeaNahuelMartinez 5 หลายเดือนก่อน

    Thanks for this info, still util !

  • @anukulghosh6575
    @anukulghosh6575 ปีที่แล้ว

    You are awesome, whats your vs code theme name?

  • @redh4y
    @redh4y ปีที่แล้ว

    Is it possible to do that using useRef rather than useState?

  • @henrymunoz2035
    @henrymunoz2035 2 ปีที่แล้ว

    Thank you so much for the great content .

  • @-Sigma111
    @-Sigma111 ปีที่แล้ว

    thanks, it helped me save more time

  • @3BDE3ALIAITTALB
    @3BDE3ALIAITTALB 3 หลายเดือนก่อน

    woooow ! genius very how is the Life with u as a genius ??

  • @mohammadDeveloper2431
    @mohammadDeveloper2431 ปีที่แล้ว

    Awesome sir very nice explain

  • @scalarcoding
    @scalarcoding ปีที่แล้ว

    Hi, I wanna ask, what if our search bar is in another functional component? do we need to pass the onchange function to parent component and then drill the keyword props to the table component?

    • @scalarcoding
      @scalarcoding ปีที่แล้ว

      Thanks I found out the answer

  • @iwantfrens5804
    @iwantfrens5804 11 หลายเดือนก่อน

    Great video!

  • @Miles09
    @Miles09 ปีที่แล้ว

    Great video, thanks.

  • @rajverma5051
    @rajverma5051 ปีที่แล้ว

    Thanks a lot man !

  • @MuneebUrRehman-fv4qk
    @MuneebUrRehman-fv4qk 9 หลายเดือนก่อน

    Thank you so much, this code filtering data from column first, but I want to filter data in both column I mean first name and last name. Please guide me or make a video. Thank You.

  • @MorrisonMac
    @MorrisonMac ปีที่แล้ว

    Life saver, thank you

  • @srs8074
    @srs8074 10 หลายเดือนก่อน +1

    You are just awesome 😊😊😊

  • @anandgomaskar2210
    @anandgomaskar2210 ปีที่แล้ว +1

    thanku so much upload this vidoe it's really hlep me

  • @itsir3211
    @itsir3211 2 ปีที่แล้ว

    It was brilliant bro thanks a lot ❤

  • @Muxitdin1
    @Muxitdin1 4 หลายเดือนก่อน

    thanks man!👍

  • @russellbanares5324
    @russellbanares5324 ปีที่แล้ว

    Nice content dude, but how can I display a error text if no search found?

    • @codecommerce
      @codecommerce  ปีที่แล้ว +1

      You could check for the results and if they are null or 0 then render some text. :)

    • @russellbanares5324
      @russellbanares5324 ปีที่แล้ว

      @@codecommerce Thanks bro, should I put that inside the filter method?