O' the mysteries of Lorem Whitman

205 views

Published on

An assortment of technical intrigues discovered in the development of loremwhitman.com.

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
205
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

O' the mysteries of Lorem Whitman

  1. 1. O, the mysteries ofloremwhitman.comWednesday, June 26, 13
  2. 2. Lorem WhitmanGenerates placeholder text by remixinglines from Walt Whitman poemslorem-whitman gemgenerates the textlorem-whitman-websiteserves text via web pageserves text via JSON APIWednesday, June 26, 13
  3. 3. Mysteries•APIs served through a middleman•JSON for all men ever born•Images fill wide expanses•Elements rest upon my whiskersWednesday, June 26, 13
  4. 4. Sinatra throughMiddleman•Sinatra app embeddedin a middleman app•Sinatra serves a JSON API•Middleman serves pages•Hosted on HerokuWednesday, June 26, 13
  5. 5. Cross-origin JSONUsed rack-cors gem# Enable cross-origin access to the apiuse Rack::Cors doallow doorigins *resource /api/*, :headers => :any, :methods => :getendendWednesday, June 26, 13
  6. 6. automagic image sizeImage fits the width of the windowbackground-size: 100% auto;Wednesday, June 26, 13
  7. 7. align: mustacheVertical position of the page is relativeto the width of the windowvw, vh, vmCSS units relative to widthand height of the viewportnot to be confused with remRelative to font-sizeof the the html elementWednesday, June 26, 13

×