Chart.js/README.md

58 lines
3.2 KiB
Markdown
Raw Normal View History

2016-04-24 23:33:25 +02:00
# Chart.js
2014-12-30 20:24:55 +01:00
[![travis](https://img.shields.io/travis/chartjs/Chart.js.svg?style=flat-square&maxAge=60)](https://travis-ci.org/chartjs/Chart.js) [![coveralls](https://img.shields.io/coveralls/chartjs/Chart.js.svg?style=flat-square&maxAge=600)](https://coveralls.io/github/chartjs/Chart.js?branch=master) [![codeclimate](https://img.shields.io/codeclimate/maintainability/chartjs/Chart.js.svg?style=flat-square&maxAge=600)](https://codeclimate.com/github/chartjs/Chart.js) [![slack](https://img.shields.io/badge/slack-chartjs-blue.svg?style=flat-square&maxAge=3600)](https://chartjs-slack.herokuapp.com/)
2014-06-29 19:37:39 +02:00
*Simple HTML5 Charts using the canvas element* [chartjs.org](http://www.chartjs.org)
2013-09-09 01:29:33 +02:00
2016-04-17 01:48:55 +02:00
## Installation
2015-09-30 23:32:16 +02:00
You can download the latest version of Chart.js from the [GitHub releases](https://github.com/chartjs/Chart.js/releases/latest) or use a [Chart.js CDN](https://cdnjs.com/libraries/Chart.js).
2015-09-30 23:32:16 +02:00
To install via npm:
2015-09-30 23:32:16 +02:00
2016-04-17 01:48:55 +02:00
```bash
npm install chart.js --save
```
2015-09-30 23:32:16 +02:00
To install via bower:
```bash
bower install chart.js --save
```
### Selecting the Correct Build
Chart.js provides two different builds for you to choose: `Stand-Alone Build`, `Bundled Build`.
#### Stand-Alone Build
Files:
* `dist/Chart.js`
* `dist/Chart.min.js`
The stand-alone build includes Chart.js as well as the color parsing library. If this version is used, you are required to include [Moment.js](http://momentjs.com/) before Chart.js for the functionality of the time axis.
#### Bundled Build
Files:
* `dist/Chart.bundle.js`
* `dist/Chart.bundle.min.js`
The bundled build includes Moment.js in a single file. You should use this version if you require time axes and want to include a single file. You should not use this build if your application already included Moment.js. Otherwise, Moment.js will be included twice which results in increasing page load time and possible version compatibility issues. The Moment.js version in the bundled build is private to Chart.js so if you want to use Moment.js yourself, it's better to use Chart.js (non bundled) and import Moment.js manually.
2014-06-29 19:37:39 +02:00
## Documentation
2013-09-09 01:29:33 +02:00
You can find documentation at [www.chartjs.org/docs](http://www.chartjs.org/docs). The markdown files that build the site are available under `/docs`. Previous version documentation is available at [www.chartjs.org/docs/latest/developers/#previous-versions](http://www.chartjs.org/docs/latest/developers/#previous-versions).
2013-09-09 01:29:33 +02:00
2016-04-17 01:48:55 +02:00
## Contributing
2013-10-17 00:28:41 +02:00
2017-04-17 16:28:35 +02:00
Before submitting an issue or a pull request, please take a moment to look over the [contributing guidelines](https://github.com/chartjs/Chart.js/blob/master/docs/developers/contributing.md) first. For support using Chart.js, please post questions with the [`chartjs` tag on Stack Overflow](http://stackoverflow.com/questions/tagged/chartjs).
2013-10-17 00:28:41 +02:00
## Building
Instructions on building and testing Chart.js can be found in [the documentation](https://github.com/chartjs/Chart.js/blob/master/docs/developers/contributing.md#building-and-testing).
2013-10-17 00:28:41 +02:00
## Thanks
- [BrowserStack](https://browserstack.com) for allowing our team to test on thousands of browsers.
- [@n8agrin](https://twitter.com/n8agrin) for the Twitter handle donation.
2015-01-02 00:49:10 +01:00
## License
2014-10-01 18:18:47 +02:00
2015-01-02 00:49:10 +01:00
Chart.js is available under the [MIT license](http://opensource.org/licenses/MIT).