A commit lands in your terminal. It bears the dreaded subject Imported from SVN.
This repository contains that commit. Someone mucked up the export from SVN and lost the project’s commit history. You can just make out through the haze of cruft ... a janky old web application written in HTML, CSS and JavaScript. Unfortunately the code has suffered dreadful blight.
Oh no!
We don’t know why this is, perhaps no one loved the code. That doesn’t matter now, let’s look at what we have in front of us. It’s not pretty:
- No documentation!
- No unit tests!
- No modules!
- No objects!
- No build process!
Let’s fix that.
This repository contains a web application that (whilst it appears to function correctly) intentionally has a number of bugs, bad practices and common mistakes. THIS CODE IS INTENDED TO SEND YOUR WTFS/MIN THROUGH THE ROOF
This homework is to find the bugs, bad practices and common mistakes and apply the good and sensible practices alluded to in the introduction (along with any that aren’t mentioned but may be applicable) to the small codebase here. Steps undertaken should be documented and justified.
Probably the easiest way to document and justify the steps taken is by carefully authoring your Git history: when you fix something, make a commit that explains what you did and why. Don’t worry, we’ll read the whole history.
Please try to address one issue at a time (there are many, we know!) and make a commit that contains only changes that address a specific bad practice. You don’t have to do this, but it will make it easier for us to see your thinking.
If there are any things that were really bugging you, but you didn’t have time to get to, write them down!