## ⚠️ This package has been deprecated

If you're currently using or planning to use this package, please consider moving to `@splunk/visualizations` as we will stop publishing bugfixes and features for this package.

Read more about the deprecation and how to migrate in our [migration doc](?path=Migration)

## General

React visualizations are react visualization components. They are designed to be standalone components that can be used without dashboard framework.

**React visualizations would not understand the result from Splunk SPL.**

## Install

Install @splunk/react-visualizations

1.  Install peer dependencies
    ```
    npm install react@^16 react-dom@^16 styled-components@5 --save
    ```
1.  Install the visualizations package
    ```
    npm install @splunk/react-visualizations
    ```

## Using the Components

Use as React component.

```js
import React from 'react';
import SingleValue from '@splunk/react-visualizations/SingleValue';

export default () => (
    <SingleValue
        value={1320}
        deltaValue={390}
        graphData={['5', '42', '206', '482', '678', '745', '893', '3278']}
        unit={'$'}
        unitPosition={'before'}
        sparklinePosition={'after'}
    />
);
```
