Navigate to: FEND P4: Website Performance Optimization
Alternatively to look at the src and dist folders within the project, navigate to: My github repository
Once there, you can:
- Check out the repository
- To inspect the site , you can run a local server
$> cd /path/to/your-project-folder
$> python -m SimpleHTTPServer 8080
- Open a browser and visit localhost:8080
- Download and install ngrok to make your local server accessible remotely. Note that I needed to add http infront of ngrok 8080 on my system unlike the original directions given for this assignment
$> cd /path/to/your-project-folder
$> http ngrok 8080
- Copy the public URL ngrok gives you and try running it through PageSpeed Insights!
- The project has already been configured with a package.json and a Gruntfile.
- Change to the project's root directory.
- Install project dependencies with npm install.
- Convert images to .webp format using www.online-convert.com and store the converted image files in the orginal folders along with the originals. The code has been updated to use the .webp files.
- Run Grunt with grunt.
- Converted images to .webp format (www.online-convert.com)
- Minimized critical css. (grunt-contrib-cssmin)
- Inlined minimized css except for the print.min.css
- JS that does not affect the DOM was changed to Async
- HTML was minimized (grunt-contrib-cssmin)
- JS files were minimized. (grunt-contrib-uglify)
- Moved unnecssary work from 'for' looks in main.js
- Reduced the number of pizzas
- John Mav Hang-out on using Grunt - Thank you John!!!
- FPS Counter/HUD Display useful in Chrome developer tools described here: Chrome Dev Tools tips-and-tricks
- Critical Rendering Path course.
- Optimizing Performance
- Analyzing the Critical Rendering Path
- Optimizing the Critical Rendering Path
- Avoiding Rendering Blocking CSS
- Optimizing JavaScript
- Measuring with Navigation Timing. We didn't cover the Navigation Timing API in the first two lessons but it's an incredibly useful tool for automated page profiling. I highly recommend reading.
- The fewer the downloads, the better
- Reduce the size of text
- Optimize images
- HTTP caching
The portfolio was built on Twitter's Bootstrap framework. All custom styles are in dist/css/portfolio.css
in the portfolio repo.