What's happening today:

  • Talk: Web APIs
  • Final Project

Application Programming Interface

There are 2 main types of Web APIs we will discuss in this course. The first has to do with device capabilities.

We call these device APIs because they define a safe way for a programmer to access device hardware through the browser.

This is analogous to the way an operating system will abstract the hardware of a computer so a programmer does not need to know the underlying details of how the hardware works.

MDN

Probably the most comprehensive up to date documentation.

Not all of these are available so be sure to check compatibility with Chrome!

  • Reference
  • Reference
  • List of Interfaces

HTML5 Rocks

Useful tutorials that mostly cover new and emerging web technologies.

  • Tutorials

Can I Use This Magic

A great resource for checking which browser supports what.

  • Site

Libraries

Wherever possible, try to find libraries or snippets of code that will abstract the API and make it easier for you to create.

A perfect example of this is Three.js or Pixi.js for WebGL.

Compare writing WebGL to Three.js code:

  • Barf
  • Yaaa!

Here's a great library that wraps up the Indexed DB API

Sklad

USE LIBRARIES WHEREVER POSSIBLE

Modernizr

This small JavaScript library allows you to detect features and fail gracefully if they are not available.

Modernizr

HTML5 Boilerplate

A kind of bloated boilerplate for building HTML5 Apps. You might not need 90% of what's in here but it's a nice collection of best practices.

HTML5 Boilerplate

Initializr

Yet another generator style tool to help you quickly scaffold projects.

Initializr