The video for this lesson is currently being updated, please read the transcript instead.

Adding search input

Now that we have our form working, let's add a text input where users can enter their search.

We'll add the input tag just above the submit button, we'll make it type text and we'll give it a placeholder value of "Search for posters".

Finally, we'll make it required since you shouldn't be able to submit without a value.

<form class="search-bar" v-on:submit.prevent="onSubmit">
  <input type="text" placeholder="Search for posters" required>

To view the complete lesson you'll need to login or join this course.


Click to load comments...