Skip to content
This repository has been archived by the owner on Mar 26, 2018. It is now read-only.

Commit

Permalink
Add PageSpeed Insights
Browse files Browse the repository at this point in the history
  • Loading branch information
robdodson committed Aug 7, 2014
1 parent 6c361e1 commit 4c6a5a5
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
20 changes: 20 additions & 0 deletions app/templates/Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,26 @@ module.exports = function (grunt) {
src: ['{styles,elements}/{,*/}*.css']
}]
}
},
// See this tutorial if you'd like to run PageSpeed
// against localhost: http://www.jamescryer.com/2014/06/12/grunt-pagespeed-and-ngrok-locally-testing/
pagespeed: {
options: {
// By default, we use the PageSpeed Insights
// free (no API key) tier. You can use a Google
// Developer API key if you have one. See
// http://goo.gl/RkN0vE for info
nokey: true
},
// Update `url` below to the public URL for your site
mobile: {
options: {
url: "https://developers.google.com/web/fundamentals/",
locale: "en_GB",
strategy: "mobile",
threshold: 80
}
}
}
});

Expand Down
1 change: 1 addition & 0 deletions app/templates/_package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
"grunt-contrib-jasmine": "~0.5.1",<% } else { %>
"grunt-mocha": "~0.4.7",<% } %>
"grunt-usemin": "~2.3.0",
"grunt-pagespeed": "~0.3.0",
"grunt-rev": "~0.1.0",
"grunt-open": "~0.2.3",
"grunt-vulcanize": "~0.3.0",
Expand Down

0 comments on commit 4c6a5a5

Please sign in to comment.