1.0.0 • Published 7 years ago

pagelt v1.0.0

Weekly downloads
3
License
MIT
Repository
github
Last release
7 years ago

Build Status

pagelt

Node.js module/CLI app for measuring time to load for a webpage.

Installation

$ npm install pagelt

You can also install it globally to use the CLI version

$ npm install pagelt -g

Test

Make sure you have installed Mocha globally or go to the pagelt folder and do an nmp install.

$ npm test

Usage - module

Pass the uri for the page you want to measure.

const plt = require('pagelt')
const uri = 'http://www.google.com' 

plt(uri, (err, data) => {
  if (error) {
    throw error
  }
  console.log(data)
})

Usage - CLI

To use it as a CLI app install it globally.

To display help

$ pagelt --help

To display version

$ pagelt --version

Usage:

$ pagelt <uri>

Output

{
  "start": 1400085247092,
  "end": 1400085247396,
  "ms": 304,
  "status": 200
}

License

MIT

Robohash image of pagelt