Open in app

Sign In

Write

Sign In

Alex Bostock
Alex Bostock

4 Followers

Home

About

Published in Nerd For Tech

·May 26, 2021

Should I use const?

When writing JavaScript, I often use const. In terms of technical differences between const and let, there is very little difference. And some people argue that const shouldn’t be used often. I recommend reading these pieces: A fucking rant about fucking const vs fucking let I didn't want to be the guy write this post, but I am because Chris told me to so blame that fuckin guy. I'm a victim…jamie.build

JavaScript

4 min read

Should I use const?
Should I use const?
JavaScript

4 min read


May 16, 2021

Variable shadowing, hoisting and the temporal dead zone

I wrote some JavaScript that didn’t work. It looked something like this: var x = 1; function f() { let x = x; // Something that modifies x }; f(); Executing that results in an error. But why? Variable shadowing I assume you are at least somewhat familiar with how local and…

JavaScript

5 min read

Variable shadowing, hoisting and the temporal dead zone
Variable shadowing, hoisting and the temporal dead zone
JavaScript

5 min read


Feb 18, 2021

How to setup a headless Raspberry Pi

Because remembering all the steps is hard. Summary of steps Write a disk image to the SD card Add wifi credentials and enable ssh Change the Pi’s hostname and add ssh key(s) Reboot Verify passwordless authentication works Disable password authentication Write a disk image to the SD card. The Raspberry Pi Imager makes this super simple. I normally choose either Raspberry…

Raspberry Pi

3 min read

Raspberry Pi

3 min read


Jan 27, 2020

Lessons about React, Keyboard Input, Forms, Event Listeners and Debugging

tl;dr: key presses can trigger all kinds of things: form inputs, browser scrolling, and app-specific keyboard controls, to name a few. Given this, writing code to handle key presses might be more complicated than you think. I built a tetris game. Its source is on GitHub. It’s built using React…

React

5 min read

Lessons about React, Keyboard Input, Forms, Event Listeners and Debugging
Lessons about React, Keyboard Input, Forms, Event Listeners and Debugging
React

5 min read

Alex Bostock

Alex Bostock

4 Followers

https://alexbostock.co.uk

Following
  • Shane Dowling

    Shane Dowling

  • Chaz Hutton

    Chaz Hutton

Help

Status

Writers

Blog

Careers

Privacy

Terms

About

Text to speech