<!DOCTYPE html>
<html>
<head>
<script>
function boom()
{
var ctx = document.querySelector("canvas").getContext('2d');
ctx.strokeRect(0.5, 1, 2, 3);
}
</script>
</head>
<body onload="boom();"><canvas width="100" height="100"></canvas></body>
</html>