- It allows you to draw 2D graphics using JavaScript.
- The "" element requires the closing tag "". Any content between the opening and closing tags is fallback content that will display only if the browser doesn’t support the "" element.
- it returns a render context object
- it is a JavaScript plugin that uses HTML5’s canvas element to draw the graph onto the page. It’s a well documented plugin that makes using all kinds of bar charts, line charts, pie charts and more, incredibly easy.
- is a charting library. You can use Chart.js directly or leverage well-maintained wrapper packages that allow for a more native integration with your frameworks of choice.
- Area
- Bar
- Bubble
- Doughnut and Pie
- Line
- Mixed Chart types
- Polar Area Chart
- Radar
- Scatter
Easily Create Stunning Animated Charts with Chart.js
Charts are far better for displaying data visually than tables and have the added benefit that no one is ever going to press-gang them into use as a layout tool.
- chart.js is easier to look at and can convey data quickly
-
"By the end of this article, you will have learned how to draw rectangles, triangles, lines, arcs and curves, providing familiarity with some of the basic shapes. Working with paths is essential when drawing objects onto the canvas and we will see how that can be done." fillRect(x, y, width, height) Draws a filled rectangle.
-
strokeRect(x, y, width, height) Draws a rectangular outline.
-
clearRect(x, y, width, height) Clears the specified rectangular area, making it fully transparent.
Applying Style and Colors - Canvas API
- Shows some amazing examples of what you can draw
- Drawing text is possible, this page shows you some of the commands