Things My Trainer Told Me Not To Do
Tags: beginners, learning, devtips
Published: 2018-08-08 16:21:25

---
title: Things My Trainer Told Me Not To Do
published: true
description: ...when I was learning how to code at [Mayden Academy](https://maydenacademy.co.uk), that you should consider not doing, too!
tags: beginners, learning, devtips
---

When I went to [Mayden Academy](https://maydenacademy.co.uk) I was inducted into the wondrous world of software development. Sometimes what you're taught to do doesn't stick with you as much as what you're taught **not** to do. That's a good thing!

Here are some sage nuggets of wisdom. Whatever you do, just remember not to...

# Skip Ahead

No! You really ought to know what a function is *before* you try to unit testing... And no, you'll find out about OOP in a few weeks. I don't care that your older brother told you it's faster in jQuery, we're learning VanillaJS first. No! Put. The. Dollar. Sign. Down!

# Bodge it

Hm... it's a good thing you all did your browser testing! After all, we're using VMs for a reason! You **did** do your browser testing, right? Okay, good. So now explain to me why only half the site is actually *on* the screen in IE11... And is there a reason you're running a loop that does nothing? 40 times?

You might feel the temptation to...

* Skip code review
* Skimp on code review
* Ignore accessibility

**Don't.**

# Make it work... no matter the cost

## `$ git push --force`

Where are everyone else's branches, Lucia? DESTROYED. BY YOU. 

## `!important`

Lucia. You just spent thirty minute trying to figure out why your red text wouldn't turn blue. You know why that was, Lucia? It's because you used bang important. What did I tell you to never, ever do (unless you're me) in css, Lucia? I TOLD YOU NEVER TO USE `!IMPORTANT`, LUCIA.

## `sudo [all the things]`

Okay look. I don't know what you did, or how it broke everything, but even though we turned it on and off again, uninstalled all the things, wiped your laptop twice, reinstalled some of the things... in the end we just had to burn it. Everything was broken all the time.

![Burning...](https://media.giphy.com/media/kHU8W94VS329y/giphy.gif)

# Change history

## `$ git rebase`

## `$ git reset --hard`
Just use `$ git revert`!

When you're new to git I guarantee you will lose something to `$ git reset --hard`.

A transparent, thorough commit history is your friend. It's also your team's friend - they need to learn from your mistake, too! And doesn't it feel better to have zero chance of losing all your work forever because you didn't run that `git reset` (and didn't know about `git reflog`)?

# Select all the things

## `SELECT *`

## `$ git add .`

DO YOU KNOW WHAT'S IN THAT DOT?! NO, LUCIA, YOU DON'T. Congratulations, you just committed the file you made to jot down the wifi details while I was talking. That could have been *patient data*, Lucia. *PATIENT DATA*. _Why would you do that to those patients, Lucia? **Why?**_

# Ignore the inspector

Your button isn't doing anything on click? Okay. What's in the console? You haven't checked?!

![Why do I bother...](https://media.giphy.com/media/nlIZ0vL7AjaMIXHZjj/giphy.gif)

Do what I did; get really fast at opening that inspector and pretending it had been there all along.

# Ignore basic security

Your queries are unparameterised, your validation is missing, your password's hashed but not salted... and you're using sha-1? Seriously peeps, bcrypt, I told you it was the only way to go. Aaaaand now I have admin access to your CMS. Look who's about to publish a blog post on how **awesome** I am!