Category Archives: Javascript

The best kind of script

Me n’ Carl Sagan hand-rolling some WebGL2

Imagine, if you may, an apple sitting happily on your desk. One day, and in a manner causing much confusion to our apple friend – you wrote some weird WebGL2 thing from scratch. From the apple’s perspective, it might look something like this. However, from a source code’s point of view it would look more […]

ES6 (ES2017+) module support

It’s been a long time coming, and we’re still on shaky ground – but native module support is close. Not “burn your build tools!” close, but “burn your build tools for personal projects!” close… like arrow function syntax in 2013. If you have Firefox Nightly, or Safari Tech Preview (or Edge, I believe!) – you […]

Building geometry with fraggles

My last experiment got out of hand and now the cubes have become self aware. See for yourself! The earlier “lil cube” example worked by creating individual box meshes and adding them to the scene. This is not a very scalable approach if we want a lot of boxes! Creating a single chunk of 16 […]

Lil’ cube-y thing

Just adding something before the new year. Gotta get those posting stats up. Lil’ cube-t thing! Made with three.js, quick-sticks. Source of course.

Functions as RxJS Subjects

Here’s a nifty trick if you’re using RxJS, and want to subscribe to plain ol’ function invocation. This is especially useful if you want to use React, and don’t want to bind with Rx.Observable.fromEvent with standard DOM event listeners. import Rx from ‘rx’; const RxFuncSubject = () => { const subject = Object.assign( (…args) => […]

Explostyx: explody 3D french fries

Some more crazy 3D action in the form of Explostyx: explody 3D french fries thing. It’s what happens when you make one simple thing and then just repeat it a whole stack of times. Like all good pop art. It’s using Three.js, and 100-odd lines of ES2015 – so it’s a pretty simple example if […]

Wanna do new JavaScript + React?

Here’s the “easiest” way to get started with the latest version of JavaScript (so much new stuff in es2105!) and the most popular kid (for this week, at least) in the JS framework playground: React. This approach uses the wonderful new JSPM package manager… so if you’re not willing to place your bet on this […]

Announcing JS.scala v0.1

I’m pleased to announce the initial releas of JS.scala. JS.scala compiles JavaScript source code to Scala source code, allowing you to write your web application entirely in JavaScript! Finally, the expressive power of JavaScript available on the JVM via Scala (some call it “the bytecode of the JVM bytecode”). How does it work? Well, given […]

Oculus Rift Reddit Internet Explorer

Recently both Firefox and Chrome released VR-enabled version of their browsers. Just as Lawnmower Man predicted. I decided to test them out with the Rift, by hacking together “Mr Speaker’s Internet Explorer” (or the repo): It loads any ImgUr images in a sub, and finds related subs mentioned in the “about” info.