---
title: "Discussion on \"Build a Custom Autocomplete Search Bar with React Hooks\" | Hashnode"
description: "Discussion on \"Build a Custom Autocomplete Search Bar with React Hooks\". Hello friends! I am back with another technical article for today's 6th article of the #2Articles1Week Challenge Series by Hashnode! First, I apologize for the absurdly long title. I just need to include all the juice in this article... \nI hope all o..."
url: "https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Build a Custom Autocomplete Search Bar with React Hooks](https://blog.lo-victoria.com/build-a-custom-autocomplete-search-bar-with-react-hooks?utm_source=hashnode&utm_medium=feed)

Hello friends! I am back with another technical article for today's 6th article of the #2Articles1Week Challenge Series by Hashnode! First, I apologize for the absurdly long title. I just need to include all the juice in this article... I hope all o...

Jul 23, 2020 · 15 min read · blog.lo-victoria.com  
Updated Dec 7, 2020  
Read the article

-   [#react-native](https://hashnode.com/tag/react-native)
-   [#frontend-development](https://hashnode.com/tag/frontend-development)
-   [#apis](https://hashnode.com/tag/apis)
-   [#2articles1week](https://hashnode.com/tag/2articles1week)
-   [#react-hooks](https://hashnode.com/tag/react-hooks)

## Written by

[Victoria Lo](https://hashnode.com/@victoria)

@victoria · Singapore

  
[View profile](https://hashnode.com/@victoria)

A nerd in books, tea, games and software.

I'm a solutions engineer lead, GitHub Star, Director of WomenDevsSG, and co founder of ragTech. I work at the intersection of tech, systems, and leadership, and this blog is where I share my journey through all three. Expect honest reflections, real experiences, and thoughts that are still forming rather than polished career advice.

## Responses 6

Markdown supported · ⌘↵ to post

[Benjamin Ik](https://hashnode.com/@wiredmatrix)

[Apr 18, 2021](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/607b8fc8eb2bd30d2d2269ef)

In a situation where am not fetching data in the network, but fetching data from my local data array in my app (eg './contactData.js'). How do I change the code below to get the data

const fetchData = async () => { const res = await fetch('[api.opendota.com/api/heroes&](https://api.opendota.com/api/heroes')); const json = await res.json(); setData(json); setHeroes(json.slice()); };

[Justin Cole](https://hashnode.com/@JustinCole)

[Oct 3, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f785ba67d160d41227d75c1)

Thanks 👍 this was a great example. I wonder if I could set the placeholder in the search bar to update too.

[Rana Emad](https://hashnode.com/@RanaEmad)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a9cbd09e95d4d18c3b48f)

Amazing job! I love your writing style and thanks for the shout-out, [Victoria Lo](https://hashnode.com/@victoria)!

[Victoria Lo](https://hashnode.com/@victoria)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a9cbd09e95d4d18c3b48f#reply-5f1ab3e2738f7959dfe1ba30)

Thanks! And your article is amazing too! I was inspired from you :)

[Edidiong Asikpo (Didi)](https://hashnode.com/@didicodes)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a806b09e95d4d18c3b332)

I love this [Victoria Lo](https://hashnode.com/@victoria). Thanks for sharing.

[Victoria Lo](https://hashnode.com/@victoria)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a806b09e95d4d18c3b332#reply-5f1ab63e738f7959dfe1ba3c)

Thanks! It was fun building this mini project too!

[Bolaji Ayodeji](https://hashnode.com/@bolajiayodeji)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a5fcc3535f04d39551588)

Amazing read! Thanks for sharing.

[Victoria Lo](https://hashnode.com/@victoria)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a5fcc3535f04d39551588#reply-5f1a602b3535f04d39551591)

Thank you! I'm glad you enjoyed it!

[Steffy Lo](https://hashnode.com/@steffy)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a5ef709e95d4d18c3b223)

Great article! Glad my article helped you :)

[Victoria Lo](https://hashnode.com/@victoria)

[Jul 24, 2020](https://hashnode.com/posts/build-a-custom-autocomplete-search-bar-with-react-hooks/5f1a192a3535f04d3955147f/comment/5f1a5ef709e95d4d18c3b223#reply-5f1a604909e95d4d18c3b23d)

Yup it did! Thanks!
