# vector-charts

> A light-weigth reusable charting library based on D3.js V5

Latest version **1.0.0** (published 2019-11-07) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install vector-charts
pnpm add vector-charts
yarn add vector-charts
bun add vector-charts
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2019-11-07 |
| First published | 2019-11-07 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 8 |
| Unpacked size | 569.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | skkart |
| Maintainers | skkart |

## Links

- npm: https://www.npmjs.com/package/vector-charts
- Repository: https://github.com/skkart/vector-charts
- Homepage: https://github.com/skkart/vector-charts#readme
- Issues: https://github.com/skkart/vector-charts/issues
- npm.io page: https://npm.io/package/vector-charts

## Dependencies (8)

- [d3-axis](https://npm.io/package/d3-axis.md) ^1.0.12
- [d3-array](https://npm.io/package/d3-array.md) ^2.3.1
- [d3-brush](https://npm.io/package/d3-brush.md) ^1.1.3
- [d3-scale](https://npm.io/package/d3-scale.md) ^3.1.0
- [d3-shape](https://npm.io/package/d3-shape.md) ^1.3.5
- [d3-selection](https://npm.io/package/d3-selection.md) ^1.4.0
- [d3-interpolate](https://npm.io/package/d3-interpolate.md) ^1.3.2
- [d3-time-format](https://npm.io/package/d3-time-format.md) ^2.1.3

## Recent versions

- 1.0.0 (latest) — 2019-11-07

## README

# vector-charts
***A light-weigth reusable charting library based on D3.js v5.***


**Timeseries Charts**
* Line Chart - [Demo](https://jsfiddle.net/46jtemnd/2/)
* Area Chart - [Demo](https://jsfiddle.net/46jtemnd/3/)
* Line + Area Chart - [Demo](https://jsfiddle.net/38q9n1vx/)
* Stacked Area Chart - [Demo](https://jsfiddle.net/46jtemnd/4/)
* Line + Stacked Area Chart - [Demo](https://jsfiddle.net/1scrhgb8/)

**Pieseries Charts**
* Pie Chart - [Demo](https://jsfiddle.net/46jtemnd/5/)
* Donut Chart - [Demo](https://jsfiddle.net/46jtemnd/6/)

**Barseries Charts**
* Bar Chart - [Demo](https://jsfiddle.net/46jtemnd/8/)
* Multi series Bar Chart - [Demo](https://jsfiddle.net/46jtemnd/7/)



## Quick Start
* Install with npm:``` npm install vector-charts```
* Install with yarn:``` yarn add vector-charts```
* Clone the repo: git clone https://github.com/skkart/vector-charts.git

Vector-charts is written in ES6, uses yarn package manager and built with webpack. \
The released bundle supports AMD, CommonJS, and vanilla environments. \
Usage example:
* Simply add the vector-charts assets to your project and include them in your HTML.
```
# Include CSS for Vector-charts
<link rel="stylesheet" type="text/css" href="vector-charts.css">

# Include Vector-charts - whole bundle, imports all Charts by default
<script src="vector-charts.min.js"></script>  
          
 # Include Vector-charts on demand - lazy bundle, imports required Charts based on demand and usage         
<script src="vector-charts-lazy.min.js"></script>

``` 
* You can create a custom bundle using webpack or your preferred bundler and import the vector-charts \
in your application as shown below:
```
import * as vc from "vector-charts"; // Import everything into a namespace (here, vc):

import {plotChart} from "vector-charts"; // To import specific module

```

## Dependencies
Imports only few modules of D3.js in vector-charts and not the entrie D3.js modules. \
Please check package.json for the various d3 packages dependencies imported.\
Requires **D3.js ^5.0.0** - Greater than V5 version.


## How to build
* Clone the repo: git clone https://github.com/skkart/vector-charts.git or ```npm install vector-charts```
* Run ```yarn install``` -- Download all project dependencies.
* Run ```yarn build``` -- Production mode, the compiled code will be in the dist folder.
* Run ```yarn start``` -- Start server on example folder to check the chart samples (open Usage.html for chart links)


## Supported Browsers
Recommended that you upgrade to the latest version of one of the below-listed browsers
- Google Chrome
- Opera
- Safari
- Firefox
- Microsoft Edge


## License
[MIT](LICENSE)

Copyright (c) 2019 Karthik S

---
_Source: https://npm.io/package/vector-charts · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
