Skip to content

Instantly share code, notes, and snippets.

@kbingman
Last active August 29, 2015 14:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kbingman/c9579ed68bb996b24e68 to your computer and use it in GitHub Desktop.
Save kbingman/c9579ed68bb996b24e68 to your computer and use it in GitHub Desktop.
Building Event Driven Applications with Javascript

Overview of Event Driven Patterns (1hr)

  • Large Scale Applications…
  • Event Driven vs. jQuery and Plugins
  • Get NPM and Dev Environment Setup
  • React in a few lines of jQuery
  • jQuery and DOM events
  • Observer Pattern

Exercises

  • Build a simple Instagram API
  • Couple API to UI with nothing but events

Modules and Closure (45min)

  • A Very Quick Intro to Browserify
  • Loose vs Tight Coupling

Exercises

  • Move our code to a module (or several)

Intro to the Flux Pattern with jQuery (1hr)

  • Data Stores
  • UI and Views
  • Dispatchers and Actions
  • Adding AJAX and server binding
  • Tying it all together with Actions
  • Server integration with Ajax

Exercises

  • Build a Store for fetched images
  • Use events to render changes
  • Build a Dispatcher

Other Event Driven Libraries (30min)

  • Events and MV* Libraries
  • Quick Intro to Flight.js
  • NPM event emitter
  • Delorean, Fluxor and Flux

Exercises

  • Move our UI Code to Flight.js,
  • Use Delorean to provide a Dispatcher

Testing Event Driven Code (30min, time permittting)

  • Mocha
  • Pure Functions and Unit tests

Exercises

  • Test our modules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment