Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Search onSubmit #18

Open
SallyMcGrath opened this issue Dec 22, 2023 · 0 comments
Open

Feature Search onSubmit #18

SallyMcGrath opened this issue Dec 22, 2023 · 0 comments
Labels
♟️ Dependent ticket This ticket depends on something else being completed first this sprint 🧩 Feature 🐇 Size Small Around an hour 📅 Week 3 Assigned during Week 3 of this module

Comments

@SallyMcGrath
Copy link
Member

SallyMcGrath commented Dec 22, 2023

18. Triggering search when submitting the form

Depends on #17

Instructions:

Still in the <Search /> component, add a onSubmit handler to the <form> tag. When the form is submitted (try clicking the search button), get the value of the state searchInput and pass it as a parameter to the search prop function that has been provided for you (the search prop is passed from the <Bookings /> component).

Note: Your submit handler should take an event parameter and add the line event.preventDefault() to prevent the browser from implicitly submitting the form

Test:

Given a searchInput field with input values entered
When the form is submitted
Then the value of searchInput is passed as a parameter to search

@github-project-automation github-project-automation bot moved this to 📋 Backlog in React Module Project Dec 22, 2023
@SallyMcGrath SallyMcGrath added ♟️ Dependent ticket This ticket depends on something else being completed first this sprint 📅 Week 3 Assigned during Week 3 of this module 🐇 Size Small Around an hour labels Dec 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
♟️ Dependent ticket This ticket depends on something else being completed first this sprint 🧩 Feature 🐇 Size Small Around an hour 📅 Week 3 Assigned during Week 3 of this module
Projects
Status: 📋 Backlog
Development

No branches or pull requests

1 participant