> For the complete documentation index, see [llms.txt](https://docs.squidrouter.exchange/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.squidrouter.exchange/old-v2-documentation-deprecated/add-a-widget/widget/react-installation.md).

# React Installation

Our full React example can be found [here](https://github.com/0xsquid/widget-integrations/tree/main/packages/cra-app).

### Basic example

After installing the npm package as outlined in [Installing the Widget](/old-v2-documentation-deprecated/add-a-widget/widget/installing-the-widget.md), add the widget into your React app:

```jsx
import { SquidWidget } from "@0xsquid/widget";
// ...

<SquidWidget config={
companyName:"Squid",
slippage:3,
// customization config
} />
```

### Customization

If you want to customize the widget, you can use the [Squid Widget Studi](https://widget.squidrouter.exchange/)[o](https://beta.widget.0xsquid.com/) and copy-paste the config code snippet into your code.

Follow the [Customization Guide](/old-v2-documentation-deprecated/add-a-widget/widget/customization-guide.md) to configure your widget, or check out the[Customization Guide](/old-v2-documentation-deprecated/add-a-widget/widget/customization-guide.md#full-configuration-example) for an implementation reference.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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://docs.squidrouter.exchange/old-v2-documentation-deprecated/add-a-widget/widget/react-installation.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.
