HTML Diff
0 added 0 removed
Original 2026-01-01
Modified 2026-02-26
1 <!DOCTYPE html> <html> <head> <title>График с помощью Chart.js</title> <script src="https://cdn.jsdelivr.net/npm/chart.js"></script> </head> <body> <canvas id="myChart"></canvas> <script> const ctx = document.getElementById('myChart').getContext('2d'); const myChart = new Chart(ctx, { type: 'line', data: { labels: ['Янв', 'Фев', 'Мар', 'Апр', 'Май', 'Июн'], datasets: [ { label: 'Продажи', data: [12, 19, 3, 5, 2, 3], backgroundColor: 'rgba(255, 99, 132, 0.2)', borderColor: 'rgba(255, 99, 132, 1)', borderWidth: 1, }, ], }, options: { scales: { yAxes: [ { ticks: { beginAtZero: true, }, }, ], }, }, }); </script> </body> </html>
1 <!DOCTYPE html> <html> <head> <title>График с помощью Chart.js</title> <script src="https://cdn.jsdelivr.net/npm/chart.js"></script> </head> <body> <canvas id="myChart"></canvas> <script> const ctx = document.getElementById('myChart').getContext('2d'); const myChart = new Chart(ctx, { type: 'line', data: { labels: ['Янв', 'Фев', 'Мар', 'Апр', 'Май', 'Июн'], datasets: [ { label: 'Продажи', data: [12, 19, 3, 5, 2, 3], backgroundColor: 'rgba(255, 99, 132, 0.2)', borderColor: 'rgba(255, 99, 132, 1)', borderWidth: 1, }, ], }, options: { scales: { yAxes: [ { ticks: { beginAtZero: true, }, }, ], }, }, }); </script> </body> </html>