I work at Mozilla. If you’re unsure about how much I love Mozilla then check out this beautiful chicken and leek pie with extra Firefox goodness. It was made by my talented girlfriend and it was delicious.
My official job title is Technical Evangelist but I prefer what it says on my business card. Part of my job is to engage with developers and designers like you and I about cool new technologies on the Web. And for those of you with no idea of what a rawket is, I made a multiplayer game called Rawkets in which players fly around in little rockets and shoot each other in the face with the latest Web technologies. It’s actually quite fun! http://rawkets.com
Like Kerri-Anne I’m also a recent graduate, last May I finished my degree in Interactive Media Production at Bournemouth University.
We should have enough time for questions at the end but also feel free to grab me in person after this talk or on Twitter. I’m always happy to help. These slides will go online after this talk and they’ll be available from my personal website. I’ll put all the details up at the end.
Open technologies Anyone can view the source code They are open technologies. Anyone can get involved in their creation; through browser developers like Mozilla, or through standards organisations like the W3C and WHATWG. Not long ago I was in a W3C meeting to explore what is needed for making games with these technologies. What was cool was that anyone was allowed to take part; which included everyday developers, employees of major browsers, and games companies. Also, these technologies are open in that anyone can view the resulting code that is used within Web pages, which is a fantastic way of learning.
Free technologies Free to use. Free to develop with They are free technologies. Anyone can use these technologies without having to pay anything, both for using the technology and developing with it. This is unlike closed environments like Flash where you have to pay to use official code editors and production environments.
Plugin-less No more reliance on third-party software They are technologies baked directly into the browser, which means no more plugins! No longer do you have to rely on users having third-party software installed to use rich media.
Interoperable They are built to work across platforms These technologies are built to work across platforms; whether that’s desktop, mobile, TV, or anything else! This makes it great to develop this way because you can be sure that it will work the same way on any platform that has support.
Cross-browser support Most major features are supported As with any technology on the Web it’s important that you can use it across all the major browsers. Fortunately the bigger and older features of HTML5 like video are supported by all the major browsers, with some of the newer and smaller features getting better support as time goes on. The situation isn’t perfect but we’re definitely in a position where these technologies can now be used in production.
There’s a fantastic website called Can I Use which lets you know what browsers support each technology. http://caniuse.com
Structure and content New elements for a modern Web Some of the most useful additions with HTML5 are the structural and content elements. I won’t be covering them all but I’d like to highlight a few of the most prominent.
<header> <section> <nav> <aside> <article> <footer> <section> describes a generic section of website, allowing content to be grouped into logical themes and areas. <header> describes the header of a website or area of content, commonly things like a logo, navigation, or header text in a body of content. <footer> describes the footer of a website or area of content, commonly things like copyright notices and supplemental navigation. <nav> describes content that aids in the navigation of a website or content <article> describes an area of content that is self-contained and could potentially be distributed through multiple methods (like RSS), commonly things like blog posts and news articles. <aside> describes an area of content that is related to the content surrounding it but that isn’t that important within itself, commonly things like pull-quotes.
<figure> <figcaption> <mark> <time> <figure> describes content that annotates the surrounding content using something like an image, video, or code. <figcaption> describes the caption of <figure> content and should therefore be placed within the <figure> element. <mark> describes words and phrases that are considered important for the purpose of referencing, like highlighting key words in a quote from another piece of content. <time> describes date or time-related content
Forms Making input less of a hassle Forms are another area of HTML5 that got a big upgrade.
type=… email, tel, url date color range There are also whole bunch of new input types for forms, including… Email, tel, and url, which cause the on-screen keyboard on mobile phones to change to remove or add relevant keys. For example, only showing numbers for an input field with a type of “tel”. Date, which makes it dead easy to let users select a date from a calendar. Color, which is an interesting type that shows a colour palette to select colour values from. Range, which limits the user to selecting a number within a defined range. http://wufoo.com/html5/
<progress> <meter> <output> Along with the added input types are brand new form elements. <progress> describes part of a form that shows progression, like the status of a file that’s uploading. <meter> describes part of a form that shows a measured outcome, like the final grade out of 10 in an exam. <output> describes part of a form that shows the results of a calculation performed by the form itself.
Security and peace of mind is of paramount importance with the new features being introduced. The Geolocation API is no exception and a browser will only be able to access your personal information if you explicitly allow it to each and every time.
Silk is a stunning example of what can be achieved by combining the simple drawing tools available in canvas. http://weavesilk.com
You can even use canvas just for simple effects on a standard Web page. David Desandro uses canvas to draw curved lines on his portfolio that indicate areas of focus. Before canvas you’d have had to have used static images or complex techniques to achieve this. http://desandro.com/portfolio/
Google Plus has a seriously cool feature that lets you take a screenshot of a page and highlight areas of interest. It’s great as a user can highlight areas of a problem and submit the screenshot for feedback. I’m unsure if they are using canvas here, but it’s not impossible for canvas to be used in this way and it’s a really innovative use of the technology. https://plus.google.com
WebGL 3D graphics platform WebGL brings the ability to provide advanced 3D graphics directly within the browser. It’s great for gaming and visualisations.
HelloRacer is a little game that lets you drive a Formula One car around your browser. It’s a beautiful example of WebGL in action. http://helloracer.com/webgl/
Rome is a music video created with WebGL. It’s an amazing example of what the technology can achieve in a real-world situation given a large and talented team. http://ro.me
Tinkercad is probably the most practical use of WebGL that I’ve seen in a production situation. It’s a Web app that allows you to create 3D objects in your browser using WebGL, then get them printed and sent to your doorstep in just a few simple clicks. It’s seriously awesome. https://tinkercad.com
This is a rather freaky example of how interesting WebGL is. It’s a demo that shows just how realistic WebGL can render materials, like skin. This isn’t much unlike the quality of modern games consoles! http://www.everyday3d.com/j3d/demo/014_Head.html
Video The reliance on Flash is over HTML5 video is one of the biggest improvements with HTML5; no longer do you have to rely on Flash to provide rich video on the Web.
SublimeVideo is a service that allows you to implement beautiful HTML5 video across all the major browsers. It’s main draw is the custom video controls that look really pretty. http://sublimevideo.net
Popcorn.js is quite simply one of the most interesting tools that exists for HTML5 video. It allows you to tie-in video to content on the Web page, meaning that you can automatically change the website content depending on what point of video is currently being played. http://popcornjs.org
Audio More Flash reliance vaporisation Along with HTML5 video comes HTML5 audio, which again means that there is now a legitimate alternative to Flash.
WebSockets Bi-directional real-time communication WebSockets are another technology at the top of my list. It allows you to provide bi-directional real-time communication between a browser and a server. This means you can push a user data instantly as soon as it becomes available. WebSockets are commonly used in situations where speed is important; like in games, the stock market, and chat.
Rawkets is the game I mentioned at the beginning that allows you to shoot your friends in the face with WebSockets and canvas. It’s still not really at a beta release level yet hence the bugs you might notice in this video, but it’s a good demo of a game created using these technologies. http://rawkets.com
Pusher is a service that lets you push data to your users in real-time using WebSockets. It’s a great example of how easy it is to use these technologies today in your project. http://pusher.com
My favourites Device APIs I cannot wait for There are so many Device APIs in the pipeline when you combine all the efforts by the various browser manufacturers. Here are just a few of my favourites.
WebNFC API RFID-like wireless communication The WebNFC API is pretty cool. It gives you the ability to transmit and receive data within distances no larger than a few centimetres. The idea is that it can be used in phones for things like payment (like the new Barclaycard), travel (think Oyster Card), and file transfer. https://bugzilla.mozilla.org/show_bug.cgi?id=674741
Foundation HTML5 Canvas Out now Paperback and digital formats Become a canvas master Learn how to animate Make two cool space games RAWKES.COM/FOUNDATIONCANVAS Foundation HTML5 Canvas is out now on Amazon and other reputable book stores. http://rawkes.com/foundationcanvas
Ask MDN Coming back this year One hour every fortnight Web development topics ASKMDN Hand-picked experts Great discussions @ASKMDN & #ASKMDN ON TWITTER And lastly, I’d like to quickly mention Ask MDN which is a project that I’m working on at Mozilla. The concept is simple. One hour every fortnight we gather a bunch of experts on Twitter to answer your questions about a particular topic. We’ve had 4 sessions to date and it’s going down really well. If you follow @AskMDN on Twitter you’ll be sure not to miss the next session. http://twitter.com/AskMDN
THANK YOU Any questions? Rob Hawkes @robhawkes Thank you. If you have any questions feel free to grab me on Twitter (@robhawkes) or email email@example.com.