> For the complete documentation index, see [llms.txt](https://docs.usegravity.app/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.usegravity.app/gravity-native/components/search.md).

# Search

A `<SearchBox/>` can be used anywhere to enable the user to perform a search. A common example is searching a table.

## Preview

<div align="left"><figure><img src="/files/cqMTiwDQoP4C42mmloFG" alt="" width="375"><figcaption></figcaption></figure></div>

## Code

```javascript
<Search callback={ search }/>
```

## Props <a href="#props" id="props"></a>

| Prop        | Description                            | Required | Value                      |
| ----------- | -------------------------------------- | -------- | -------------------------- |
| callback    | function executed on change and submit | required | function                   |
| placeholder | placeholder text                       | optional | string *(default: Search)* |
| value       | initial value                          | optional | string                     |
