Conclusion

In this tutorial, we created a basic template that all future canvas-related content will follow. You have your canvas element in the HTML with some optional CSS and inline HTML attributes to help style it. You then have your JavaScript where you reference the canvas element, gain access to its rendering context, and then issue the draw commands needed to get pixels to appear.