#Building APIs
#Overview
- What is an API?
- Why build an API?
- Who is going to use it?
- What are they going to do?
- REST Architecture
- Stateless
- Resource Representations
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<title>PizzaShack</title> | |
<%= stylesheet_link_tag 'application', media: 'all' %> | |
<%= javascript_include_tag 'application' %> | |
<%= csrf_meta_tags %> | |
</head> | |
<body> |
gem 'pg' | |
group :development do | |
gem 'ruby-debug' | |
end | |
gem 'rake', '~> 0.8.7' | |
gem 'devise' | |
gem 'oa-oauth', :require => 'omniauth/oauth' | |
gem 'omniauth' | |
gem 'haml' | |
gem 'dynamic_form' |
#Building APIs
#Overview
function Dinosaur(color){ | |
this.id = Dinosaur.prototype.counter++; | |
this.dob = Date.now(); | |
this.color = color; | |
}; | |
Dinosaur.prototype.roar = function(){ | |
console.log('RARWARARRR said the ' + this.color + ' Dinosaur!!!'); | |
}; |
#Object Oriented Javascript
#Overview
new Object();
this