1.0.2 • Published 7 years ago
mini-speed-chart v1.0.2
mini-speed-chart
Detect connection speed with JavaScript
Install
Install with npm
$ npm install mini-speed-chartOr install with yarn
$ yarn add mini-speed-chartimport MiniSpeedChart from 'mini-speed-chart';Or umd builds are also available
<script src="path/to/miniSpeedChart.js"></script>Will expose the global variable to window.MiniSpeedChart.
Usage
// Init
var chart = new MiniSpeedChart({
canvas: '',
url: '',
width: 180,
height: 20,
size: 2,
backgroundColor: '#000',
lineColor: '#4f0',
detectCallback: result => result
});
// Destroy
chart.destroy();License
MIT © Harvey Zack