-
-
Notifications
You must be signed in to change notification settings - Fork 28
Feature Search onSubmitΒ #18
Copy link
Copy link
Open
Labels
βοΈ Dependent ticketThis ticket depends on something else being completed first this sprintThis ticket depends on something else being completed first this sprintπ Size SmallAround an hourAround an hourπ
Week 3Assigned during Week 3 of this moduleAssigned during Week 3 of this moduleπ§© Feature
Metadata
Metadata
Assignees
Labels
βοΈ Dependent ticketThis ticket depends on something else being completed first this sprintThis ticket depends on something else being completed first this sprintπ Size SmallAround an hourAround an hourπ
Week 3Assigned during Week 3 of this moduleAssigned during Week 3 of this moduleπ§© Feature
Type
Projects
Status
π Backlog
18. Triggering search when submitting the form
Depends on #17
Instructions:
Still in the
<Search />component, add aonSubmithandler to the<form>tag. When the form is submitted (try clicking the search button), get the value of the statesearchInputand pass it as a parameter to thesearchprop function that has been provided for you (thesearchprop is passed from the<Bookings />component).Note: Your submit handler should take an
eventparameter and add the lineevent.preventDefault()to prevent the browser from implicitly submitting the formTest:
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