yslow-grader

0.0.3 • Public • Published

yslow-grader

A very simple JavaScript API wrapping the command-line combo of phantomjs and yslow.

Build Status

Right now, it's a dead simple usage. Something like this:

YslowGrader = require("yslow-grader")
yslowGrader = new YslowGrader()
yslowGrader.visit("http://google.com", function(result) {
  console.log(result.raw) //=> the raw results; that is, the JSON YSlow returns
  console.log(result.raw.o) //=> the Overall numeric score of the page.
});

Assumptions:

  • PhantomJS has to be on your path. A configuration option should be added later.
  • The "-i grade" option with default rule configuration is what you want. Configuration should be added later.
  • You don't need error handling. Error handling should be added later.

Readme

Keywords

none

Package Sidebar

Install

npm i yslow-grader

Weekly Downloads

2

Version

0.0.3

License

none

Last publish

Collaborators

  • dustin.tinney
  • mike.testdouble
  • searls