Skip to content

@artlung /Canvas Hello World.html
Created

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
<canvas> Hello World, thanks @miketaylr!
<html>
<head>
<script>
window.onload = function() {
var ctx = document.querySelector('#c').getContext('2d');
ctx.lineWidth = 20;
ctx.lineCap = 'square';
ctx.lineJoin = 'round';
ctx.strokeStyle = '#c9f'; // 'rgb(247, 63,20)';
ctx.strokeRect(10,10,346,230);
}
</script>
<body>
<canvas id="c" height=400 width=400></canvas>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.