-
Listen to your heart
Posted on
by
JavaScript is responsible for the behaviour of your website/app. At the heart of affecting the behaviour of the page is listening for user interaction events. These are things like button clicks, key presses and drags and drops. To do this, first we…
-
This is our concern, Dude
Posted on
by
In web development, there’s a concept called “the separation of concerns” between your HTML, CSS and JavaScript. Each language plays a role in web development and it pays to remind ourselves what these roles are: HTML = Structure CSS = Appearane JavaScript…
-
DOM DOM DOM
Posted on
by
Playing with the DOM is all about adding interactivity to your page. The DOM (Document Object Model) is the interface between your JavaScript and your HTML+CSS. The browser takes all the elements of your page and turns it into a JavaScript object.…
-
GitHub flow
Posted on
by
I’ve recently been attempting to contribute to some open-source GitHub projects with varying degrees of success. One thing that’s extremely useful to do before you start contributing is to develop a basic understanding of the standard GitHub workflow. It’s not especially complicated…
-
Load scripts last
Posted on
by
So you’ve got your HTML and CSS sorted and you’ve started to drop in some customs scripts to make things a bit interactive. To keep things in shape it pays to develop some good habits early on. One such habit is placing…
-
No Comments
Posted on
by
When I was first learning to code, something that came up a lot was to always comment your code. Code comments have value, but despite what my teachers at the time may have thought, you should try not to rely on comments.…
-
DRY variables
Posted on
by
The concept of DRY code is simple, Don’t Repeat Yourself. So if you look at some code you’ve just written and notice it’s looking a bit moist, AKA the same stuff repeating over and over, there’s a good chance it’s an opportunity…
-
Equals vs equals
Posted on
by
In JavaScript not all comparisons are created equal… see what I did there. Let’s say we’re comparing two values like this: The use of “==“ will compare two values regardless of their type, so in this example, it will return “The meaning…
-
Zombie code
Posted on
by
Part of developing (and certainly learning to develop) is creating code, commenting it out, and creating a better version. As you get into a flow state with coding it’s really easy to get into the habit of doing this and not going…