Skip to content

Instantly share code, notes, and snippets.

@stefanjudis
Created September 2, 2014 11:54
Show Gist options
  • Save stefanjudis/6f6cd72b5ddaa76ac564 to your computer and use it in GitHub Desktop.
Save stefanjudis/6f6cd72b5ddaa76ac564 to your computer and use it in GitHub Desktop.
phantomas.js
/**
* grunt-phantoms configuration
*
* https://www.npmjs.org/package/grunt-phantomas
*/
'use strict';
module.exports = function() {
return {
home : {
options : {
assertions : {
// REQUESTS
requests : 35,
postRequests : 0,
gzipRequests : 10,
notFound : 0,
assetsNotGzipped : 5,
// HTML
bodyHTMLSize : 92000,
iframesCount : 0,
imagesWithoutDimensions : 4,
commentsSize : 40,
DOMelementsCount : 550,
DOMelementMaxDepth : 15,
nodesWithInlineCSS : 4,
// JAVASCRIPT
documentWriteCalls : 7,
consoleMessages : 0,
windowAlerts : 0,
windowPrompts : 0,
windowConfirms : 0,
globalVariables : 50,
// DOM
DOMqueries : 30,
DOMqueriesDuplicated : 15,
DOMinserts : 30,
// CCOUNTS & SIZES
cssCount : 1
},
indexPath : './phantomas/',
options : {
'no-externals' : true,
'allow-domain' : 'cdn.foo.com.br,ajax.googleapis.com,static.foo.com.br'
},
url : 'http://www.foo.com.br'
}
}
};
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment