A web playground, demonstrating variety of website development techniques using best practices and standards.
Built for the University of Bristol unit Web Technologies.
Install dependencies and read about grunt first!
npm install
sudo npm install -g grunt-cli
(to installgrunt
globally)grunt server
- view at http://localhost:3001/
-
Clone project with Git.
git clone git@github.com:harrymt/web_playground.git
-
Navigate to that directory
cd web_playground
-
Install NodeJS
-
Install Ruby.
-
(optional) Install global SCSS linting with:
gem update --system && gem install scss_lint
- OR:
sudo apt-get install scss_lint
-
Install sqlite3 is setup and added to your PATH
The whole project uses GruntJS
to handle everything from running to deployment.
- Run
node_modules/grunt-cli/bin/grunt
to run grunt, or - Install grunt globally, with
sudo npm install -g grunt-cli
Each one of the following tasks should be run using grunt <task>
e.g. grunt build
.
/**
* Start Server.
*
* Start a Node server - view at localhost:3001.
*
* $ grunt server
*/
grunt.registerTask('server', ['exec:server']);
/**
* Build.
*
* Minify and create CSS files
*
* $ grunt build
*/
grunt.registerTask('build', ['uglify', 'sass']);
/**
* Deploy.
*
* Deploy to heroku server then run page insight tests
*
* $ grunt deploy
*/
grunt.registerTask('deploy', ['lint', 'build', 'exec:deploy', 'pagespeed']);
- To deploy download Heroku CLI
- Login to heroku by typing
heroku login
These scores were for the hosted version of this site on heroku (currently offline).
- < 32% per load Content served - Browser Calories
- 99/100 Mobile SEO
- 95/100 Yellow Lab Tools
- 90/100 desktop, 74/100 mobile Google PageSpeed Insights
- 89/100 Lets Validate
- 89/100 Web Bloat score
- 87/100 Coach Panel
- 86/100 PageLocity
- 85/100 Progressive Web App LightHouse
- 80/100 SSL Security Check
- 74/100 Mobile Speed
- 53/100 CryptCheck
- 50/100 Mozilla Observatory
- 40/100 Security Headers
- Run static analysis tools on CSS, HTML and Javascript