diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 000000000..176a458f9 --- /dev/null +++ b/.gitattributes @@ -0,0 +1 @@ +* text=auto diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000..3c3629e64 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +node_modules diff --git a/Gruntfile.js b/Gruntfile.js new file mode 100644 index 000000000..b07a3f2c9 --- /dev/null +++ b/Gruntfile.js @@ -0,0 +1,56 @@ +'use strict'; + +module.exports = function (grunt) { + var ngrok = require('ngrok'); + + // Load grunt tasks automatically + require('load-grunt-tasks')(grunt); + + grunt.initConfig({ + connect: { + server: { + options: { + port: 8000 + } + } + }, + pagespeed: { + options: { + nokey: true, + locale: "en_US", + threshold: 40 + }, + local: { + options: { + strategy: "desktop" + } + }, + mobile: { + options: { + strategy: "mobile" + } + } + } + }); + + grunt.registerTask('server', ['connect:server:keepalive']); + + grunt.registerTask('psi-ngrok', 'Run pagespeed with ngrok', function() { + var done = this.async(); + var port = 8000; + + ngrok.connect(port, function(err, url) { + if (err !== null) { + grunt.fail.fatal(err); + return done(); + } + grunt.config.set('pagespeed.options.url', url); + grunt.task.run('pagespeed'); + done(); + }); + }); + + // Register default tasks + grunt.registerTask('default', ['connect', 'psi-ngrok']); + +}; diff --git a/img/cam_be_like.jpg b/img/cam_be_like.jpg index a416eba29..629087660 100644 Binary files a/img/cam_be_like.jpg and b/img/cam_be_like.jpg differ diff --git a/img/mobilewebdev.jpg b/img/mobilewebdev.jpg index 994467e07..88e1b43d0 100644 Binary files a/img/mobilewebdev.jpg and b/img/mobilewebdev.jpg differ diff --git a/img/profilepic.jpg b/img/profilepic.jpg index 855172dd8..0ed10a7a1 100644 Binary files a/img/profilepic.jpg and b/img/profilepic.jpg differ diff --git a/index.html b/index.html index c599b101b..662697109 100644 --- a/index.html +++ b/index.html @@ -8,21 +8,60 @@ Cameron Pittman: Portfolio - + - - + + @@ -62,4 +101,13 @@

© Web Performance 2014

+ + + diff --git a/package.json b/package.json new file mode 100644 index 000000000..cf778aa9f --- /dev/null +++ b/package.json @@ -0,0 +1,26 @@ +{ + "name": "udportfolio", + "version": "0.0.0", + "description": "Your challenge, if you wish to accept it (and we sure hope you will), is to optimize this online portfolio for speed! In particular, optimize the critical rendering path and make this page render as quickly as possible by applying the techniques you've picked up in the [Critical Rendering Path course](https://www.udacity.com/course/ud884).", + "main": "index.html", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "repository": { + "type": "git", + "url": "https://github.com/asapach/udportfolio.git" + }, + "author": "", + "license": "ISC", + "bugs": { + "url": "https://github.com/asapach/udportfolio/issues" + }, + "homepage": "https://github.com/asapach/udportfolio", + "devDependencies": { + "grunt": "^0.4.5", + "grunt-contrib-connect": "^0.8.0", + "ngrok": "^0.1.95", + "grunt-pagespeed": "^0.2.0", + "load-grunt-tasks": "^0.6.0" + } +}