1
Next: http://youtu.be/DMIkh2o8xrE
Source Version: http://lifeofadreamer.com/html5-game-framework-part-1-setup-the-canvas/
Setting up the webpage “index.html” canvas element to display our stuff.
Twitter ► http://brentfarris.com/twitter
Website ► http://brentfarris.com
GitHub ► http://brentfarris.com/github
source
6 comments
<style type="text/css">
* {margin:0;padding:0;}
html, body
{
background-color: #000;
overflow: hidden;
height: 100%;
}
It doesn't work for me
*height
This looks like an awesome tutorial I'm glad I found it!!
This would be true in most cases, such as working with a big team or having multiple objects use the same style. However this HTML document has about 5 lines of code and really is no need for any CSS file. In fact it would be easier just to stick it into a "style" tag in the head (which is a better choice in small files). There is no issues with working with in-line styles in this case (mostly because of its tiny size and being a test bed).
So in this case I would dis-agree.
Dont use inline styles! stick it all in its own css file
@PcCouchPotato Yes, thank you 🙂
Comments are closed.