<p align="center">
  <img alt="Firesquad" src="https://app.firesquad.io/public/firesquad-logo-background.png">
</p>

<p align="center">
    Firesquad Widget
</p>

## Guide

- [Install](#install)
  - [React](#react)
  - [Html](#html)



## Install

```bash

npm i @firesquad/widget --save

yarn add @firesquad/widget

```

#### React

on your index file:

```javascript

import React, { useEffect } from 'react'
import Firesquad from '@firesquad/widget'

const appId = 'xxx' // Get your appId https://app.firesquad.io

const App = () => {
  useEffect(() => {
    Firesquad(appId)
  }, [])
}

```

#### Html

- Add the script with your key (replace `xxxx` with your key) <script src="https://unpkg.com/@firesquad/widget@2.0.0/dist/index.js?key=xxxx"></script>

Example:

```html

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
  <script src="https://unpkg.com/@firesquad/widget@2.0.0/dist/index.js?key=xxxx"></script>
</body>
</html>
```

  [@firesquad 2021](https://app.firesquad.io)