RSSAmplifier

Blog

etoxin

Music, Film, Web Stuff

etoxin.netRSS feed ↗15 posts

Latest posts

Type guard a filtered array with TS user-defined type guards.

When you filter a mixed type array, the new typing is not passed to the new array. In the example below the returned type of the array is ` (string | number | boolean)[] const arr = [123, true, "I'm a string"]; // Normal filter const normal = arr.filter((pred) => typeof pred === 'number'); // normal

Mogwai - Ritchie Sacramento

High Tension - Ghost to Ghost

High Tension High Tension

Carla Geneve - Dog Eared

Small Data Project

For the last couple of months I've been creating a Wikipedia for data like website with an open API (Small Data Project). I've been hesitant to post about it but thought now is better than never. Below is a sample NSW COVID-19 Dataset & API. https://smalldataproject.com/dataset/nsw-covid-19-cases

Sometimes I get bored and make stuff like this.

Sometimes I get bored and make stuff like this. Run this in your browser console for a bit of fun.

A Short Introduction to TensorFlow.JS

So this is a quick introduction for machine learning with JavaScript. Above is a series of numbers. You can work out pretty easily that Y = 2X – 1. How you worked this out in your head is exactly how machine learning works. This is all the code you need to predict

SynthWave '84 Theme

I added @robb0wen 's SynthWave '84 theme to https://carbon.now.sh . Get it while it's hot.

Cryptolist

I hear Bitcoin is on the rise. I created this tool a while back. `npx cryptolist` Offers currency conversion `npx cryptolist -c aud`. Get a list of the current prices of cryptocurrencies. Installation npm install -g cryptolist To Upgrade run npm upgrade -g cryptolist Usage On your cli enter the

Get the currently playing song on Triple J via the Command Line

I made a tiny npm library that gets the currently playing song on the radio station Triple J. This tool works on the command line. If you have npx installed, you can use it like so. npx triplej If you want to open the song in Spotify, you can use

Slack Beer Bot

I created a simple slack beer bot. It allows you to search for beer. In slack type /beer then any beer you want to look up. Here are a few examples: /beer corona /beer newtowner /beer Hop Sauce /beer Wayward Brewing /beer westvleteren 12 /beer anything really Visit https://slackbeer.

What would a Immediately Invoked Class Expression look like in JavaScript?

What would a Immediately Invoked Class Expression in JavaScript look like. This is the question I asked myself. I couldn’t find anything online, so I created one. Below we have a Immediately Invoked Class Expression. This could also be called a Self-Executing Anonymous Class. void new class { constructor () { statements

NPM Module classList-helper version 1.1.2

classList update I’ve just updated the npm module https://www.npmjs.com/package/classlist-helper to 1.1.2 It now has full unit testing. Introduction A Element.classList method helper function that can be curried for functional programing. Example Task : Add the class active to all list elements. <

npm browser-classes

I’ve just released version 1.0.1 of a new npm module browser-classes. https://npmjs.com/package/browser-classes browser-classes Adds browser classes to document body. For better cross-browser SCSS styling. This library adds the current browser and version to the <body> tag as a class to the

GIT Cheat Sheet

As a front end developer tools like source tree and Webstorm’s GIT GUI are life savers. But sometimes you need to open up the terminal to work with your GIT repo. Over the years I’ve saved a few commands that I use frequently. There are a few commands