3 ms·
<canvas> doesn't do anything by itself; you draw on it using JavaScript. Someone could argue that because JS can be embedded in HTML, it's really a part of HTML
by eurleif 11y ago
<canvas> doesn't do anything by itself; you draw on it using JavaScript. Someone could argue that because JS can be embedded in HTML, it's really a part of HTML, which makes HTML a programming language; but the HTML standard does not require JS support, and most browsers have an option to disable support, so I think they are separable.
- halosghost 11y agoImho, your latter statement would be true except for the inclusion of <canvas> which is there specifically to allow it to be manipulated by JS. You are, of course, correct though, <canvas> is not actually Turing complete without JS; but then a Turing machine cannot operate without both the ticker tape and the pen to write on it. Given that, JS + <canvas> seems to be a near perfect analog to a Turing machine to me. (Though, I can think of numerous ways that someone might disagree.) Either way, I would still like to see more in-depth analyses of this interaction; and I find it odd that a discussion of HTML as a programming language would make no mention of it whatsoever.
- BraveNewCurency 11y agoIf you have JavaScript (obviously Turning complete by itself), why do you need canvas?