# Introduction

## Installation

The package is published as `react-sheets-import` on npm and thus can be installed through:

```bash
# For yarn users:
yarn add react-sheets-import

# For npm users:
npm install react-sheets-import
```

## Basic Example

```javascript
import { Types, mapColumnsToRows } from 'react-sheets-import';

const User = Types.Object({
    name: Types.String(),
    email: Types.String()
});
const rows = [
    ['John', 'john@gmail.com'],
    ['Jane', 'jane@gmail.com']
];
const users = mapColumnsToRows(User, rows);
```

In the above example, `users` evaluates to:

```javascript
[
    {
        "name": "John",
        "email": "john@gmail.com"
    },
    {
        "name": "Jane",
        "email": "jane@gmail.com"
    }
]
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://gabin.gitbook.io/react-sheets-import/master.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
