node package manager
Share your code. npm Orgs help your team discover, share, and reuse code. Create a free org ยป


Ophan Tracker JS

Browser JavaScript client for Ophan.


$ npm install ophan-tracker-js


Proxy tracker-ts:

  1. Install dependencies

    $ brew install lighttpd
    .../ophan/tracker-js $ npm install
  2. In one terminal window:

    .../ophan/tracker-js $ grunt
    .../ophan/tracker-js $ grunt watch
  3. In another terminal window:

    .../ophan/tracker-js $ lighttpd -f lighttpd.conf -D
  4. Install FoxyProxy ( in your browser and create a rule that forces to localhost 8000. (For me FoxyProxy needed a few switches on and off before it decided to start talking to lighttpd.)

  5. In another terminal window, start a server that is running the Guardian frontend

  6. Navigate to where you are running the Guardian locally (e.g. http://localhost:9000/uk)

  7. Ensure FoxyProxy is enabled

  8. Develop with pleasure


Ophan's tracker-js is published on NPM, so it can be installed in applications such as the Guardian Frontend and Membership Frontend.

Ensure that before you merge a change, you first bump the version in package.json. Please make sure you update the file too. If you have added a new Ophan client to support a new platform, please add the path to the built output file to the files list in package.json.

Publish to NPM

Log into NPM

$ npm login


.../ophan/tracker-js $ npm publish

You will need to be added as an owner of ophan-tracker-js. To find the current owners:

$ npm owner ls ophan-tracker-js