> ## Documentation Index
> Fetch the complete documentation index at: https://docs.zopio.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Fuse.js

> A powerful, lightweight fuzzy-search library, with zero dependencies.

### Installation

To install `fuse.js`, simply run the following command:

```sh Terminal theme={"system"}
pnpm add fuse.js
```

### Usage

Here is an example of how to use `fuse.js` for searching through an array of objects:

```tsx search.ts theme={"system"}
import Fuse from 'fuse.js';

const data = [
  { id: 1, name: 'John Doe', email: 'john.doe@example.com' },
  { id: 2, name: 'Jane Doe', email: 'jane.doe@example.com' },
];

const fuse = new Fuse(data, {
  keys: ['name', 'email'],
  minMatchCharLength: 1,
  threshold: 0.3,
});

const results = fuse.search('john');

console.log(results);
```

### Benefits

* <Icon icon="check" iconType="solid" /> **Easy to Use**: `fuse.js` is easy to use and has a simple API.
* <Icon icon="check" iconType="solid" /> **Performant**: `fuse.js` is performant and has zero dependencies.

For more information and detailed documentation, visit the [`fuse.js` GitHub repo](https://github.com/krisk/fuse).
