Code Monkey home page Code Monkey logo

passbookbridge's Introduction

Simple Passbook webservice bridge Passbridge.js: A passbook overlay is detected by polling for a pause in JavaScript. Scrolling also causes a pause in JS so 'touchmove' events are captured while polling. RequestAnimationFrame is used because it is tied to the kind of throttling we are looking for. Animations are always paused when not visible.

Omniture.js: Provides a wrapper for apple metrics.js allowing omniture vars to be set in the html. Index.html in particular will fire one of three different pageName values depending on whether device is iOS and if a pass is being generated or already created.

File compression: Yui compressor is used for main.css -> main_compressed.css, and Closure is used for passbridge.js -> passbridge_compressed.js. Omniture.js is also compressed with Closure but requires that metrics.js and other dependencies be prepended. See omniture.js comments for the complete list.

Build Script (requires closure and yuicompressor):

cd /users/chase/Sites/passbookbridge/js 
closure --js passbridge.js --js_output_file passbridge_compressed.js
closure --js bootstrap.js --js coherent.js --js apple.js --js metrics.js --js omniture.js  --js_output_file omniture_compressed.js

cd /users/chase/Sites/passbookbridge/css
yuicompressor main.css -o main_compressed.css

function closure() {
    java -jar /Users/chase/Developer/tools/compiler-latest/compiler.jar $@
}

passbookbridge's People

Contributors

chase-martin avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.