pulse/README.md

2.6 KiB

Pulse icon

pulse

i Available on Test Pilot CircleCI

Pulse is an upcoming Test Pilot experiment that intends to align user satisfaction and perceived performance with more traditional performance metrics.

Development

Prerequisites: node v7.0.0, npm v3.10.

  1. Create a new profile for Pulse development. Launch that profile in either Developer Edition or Nightly.

  2. Install the DevPrefs and Extension Auto-Installer add-ons.

  3. Clone the repository and install the dependencies:

    git clone https://github.com/mozilla/pulse.git
    cd pulse
    npm install
    
  4. Run the following command to build the extension and install it to Firefox. While running, it will watch for changes and update the browser to the latest version of the add-on:

    npm run watch
    
  5. Use the Browser Console to debug. Filter the log with pulse. to filter out messages not logged by Pulse.

Architecture

Pulse is an Embedded WebExtension; an SDK add-on that wholly wraps a WebExtension.

The SDK add-on is responsible for:

  • Creating a <notificationbox> element to collect prompted feedback.
  • Establishing a communication channel with the WebExtension.
  • Collecting browser analytics to be submitted to telemetry.
  • Relaying those analytics to Test Pilot for submission.

While the WebExtension:

  • Adds the toolbar icon to the address bar.
  • Serves the survey to collect information from the user.

Style

Pulse follows the default formatting recommendations provided by prettier, but with single quotes. To lint the source tree:

npm run lint

Builds will fail if linting fails.

To automatically clean up the working tree, run:

npm run prettier

More Information