Smooth Scrolling Sticky ScrollSpy Navigation

Yesterday evening I was working on some documentation pages. The page layout is quite classic, as it consists of a content pane on the left and a sidebar navigation on the right. Looking for a way to make the page less dull I decided to add a few small things to it: Smooth Scrolling when […]

Snowpack – build modern web apps without a bundler

Must say I’m quite excited about Snowpack (formerly known as @pika/web, which I covered here) which just got released. With Snowpack you can build modern web apps (with React, Vue, etc.) without a bundler (like Webpack, Parcel, Rollup). No more waiting for your bundler every time you hit save. Instead, changes are ready in the […]

IsoCity – A Isometric City Builder in JavaScript

A simple JavaScript city builder with no simulation at all. No budget, no goals. Just build your tiny city. This would work on a phone, but it wasn’t designed with phones in mind. I especially like that the URL changes while drawing, so your designs are immediately shareable. IsoCity – A isometric city builder in […]

Enterprise React in 2020

Viacheslav Luschinskiy goes over the utils and libraries they use for building React apps. It is the opinionated set of libraries and technical approaches to quickly build scalable enterprise class applications in React. It also comes with the small demo app which can be used as a bootstrap kit. It includes all the mentioned libraries […]

JavaScript: var vs let vs const

Nice Doodle by Abhishek Kumar explaining the difference between JavaScript’s var, let, and const: Good to see hoisting is also explicitly mentioned by name. πŸ’β€β™‚οΈ I personally always start with const. Only if I need to reassign a variable’s value (for example: a counter in a loop) I use let. I see no good reason […]

ESNext: Replace all occurrences of a piece of text in a string with String.prototype.replaceAll

An ECMAScript Language feature that’s currently in Stage-3 is String.prototype.replaceAll, a handy way to replace all instances of a piece of text in a string. Stage-3? πŸ’β€β™‚οΈ To develop new ECMAScript language features, TC39 uses a 5 stage process, ranging from Stage-0 to Stage-4. Stage-3 is the Candidate Stage where the feature is considered complete […]

JavaScript File Format Differences: The difference between Generic JavaScript, JavaScript Modules, and CommonJS Modules

There’s the pervarsive notion that all JS is created equal and that there’s only minor and easily detectable differences between the various file formats used to author JavaScript. This is correct, from a certain point of view. Very resourceful Gist which highlights the key differences between Generic JavaScript, JavaScript Modules, and CommonJS Modules! Take the […]

Have a web page prevent your screen/computer from dimming/sleeping with the Wake Lock API

On some sites you don’t want the screen to dim (and eventually turn off) when left idle. Think of a run-tracking app, a puzzle game that takes device motion input, a recipe site for example: you’d want to keep the screen awake even if there is no touch input. This is where the Wake Lock […]