A search input component. The component will automatically render as a Material Design search input on Android devices. Most attributes that can be used for a normal <input> component can also be used on the <v-ons-search-input> component.


Search input

Search input elements are created using the VOnsSearchInput component. It works almost exactly the same as a normal <input type="search"> tag.

An attribute input-id is provided to set the ID of the inner native element. This is useful for HTMLLabel elements: <label for="some-inner-input">.

In Material Design the placeholder can be made to float using the float prop.

Using v-model

Search input are compatible with v-model directive. The only exception are modifiers (as of vue@2.3). There is, however, a workaround for lazy modifier:

<v-ons-input v-model="something" model-event="change"></v-ons-input>

This will use change event instead of input when updating v-model.

See also


Name Type Default Value Description
input-id String Specify the “id” attribute of the inner <input> component. This is useful when using <label for="..."> components. Optional.

Preset Modifiers

Name Description
material Displays a Material Design search input.


Need Help?

If you have any questions, use our Community Forum or talk to us via Gitter chat. The Onsen UI team and your peers in the community will work together to help solve your issues.

For bug reports and feature requests use our GitHub Issues page.