Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Intro to Meteor

Intro to Meteor

Meteor.js intro presented as part of the TriangleJS "Discover Meteor (with others!)" event.

http://www.meetup.com/Triangle-JavaScript/events/158702612/

Mark Shropshire

February 18, 2014
Tweet

More Decks by Mark Shropshire

Other Decks in Technology

Transcript

  1. What’s Meteor? “Meteor is an open-source platform for building top-

    quality web apps in a fraction of the time, whether you're an expert developer or just getting started.” http://meteor.com
  2. What’s Meteor? CLI tool: meteor meteor create myNewApp myNewApp: created.

    ! To run your new app: cd myNewApp meteor cd myNewApp meteor => Meteor server running on: http://localhost:3000/ $ $ $ [[[[[ ~/Sites/myNewApp ]]]]]
  3. What’s Meteor? • http://docs.meteor.com/#api • Node Fibers • DDP (Distributed

    Data Protocol) • Works identically in the browser
 and on the server (when possible) A wonderful API
  4. Is Meteor MVC? No, Model View View-Model (MVVM) Model View

    View-Model Client code HTML Templates Synchronized data Source: Getting Started with Meteor.js JavaScript Framework by Issac Strack
  5. Why Meteor? Seven Principles of Meteor • Data on the

    Wire • One language • Database Everywhere • Latency Compensation • Full Stack Reactivity • Embrace the Ecosystem • Simplicity Equals Productivity Source: http://docs.meteor.com/#sevenprinciples
  6. Why Meteor? Database Meteor server Meteor web applications Data Client

    Initial package Client Polling Data updates Local DB write (sync) DB writes (async)
  7. Why Meteor? DDP (Distributed Data Protocol) • RPC from client

    to server • Client subscriptions to sets of documents • JSON objects/EJSON field specifications • Introducing DDP • DDP Specificaiton
  8. Meteorite mrt add iron-router ✓ iron-router ! Done installing smart

    packages Stand back while Meteorite does its thing ! Done installing smart packages Ok, everything's ready. Here comes Meteor! ! iron-router: Routing specifically designed for Meteor $ $ http://oortcloud.github.io/meteorite - Installer and package manager for Meteor
  9. App Structure • Some folders are “special” • Flexibility server

    lib client private public tests tests compatibility
  10. Testing • Possible official testing framework for 1.0 • Laika

    testing framework for Meteor • Testing with Meteor book