Get started with peity CDN

MIT licensed

Peity: Lightweight, customizable library for pie, line, and bar charts.

Tags:
  • jquery-plugin
  • ecosystem:jquery
  • chart
  • graph
  • sparkline
  • svg

Stable version

Copied!

How to start using peity CDN


<!DOCTYPE html>
<html>
<head>
    <title>Get started with peity CDN - cdnhub.io</title>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/peity/dist/themes/time.css">
    <script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
    <script src="https://cdn.cdnhub.io/peity/3.3.0/jquery.peity.min.js"></script>
</head>
<body>
    <div id="chart1" style="width: 300px; height: 200px;"></div>
    <script>
        $(function() {
            $('#chart1').peity('line', {
                fill: ['#FADBD8', '#FFC3C7'],
                data: [65, 59, 80, 81, 56, 55, 40],
                labels: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
            });
        });
    </script>
</body>
</html>
Copied!
Copied!

All versions