C’mon Mr Speaker, stop re-writing your “distance” function every project… Math.hypot() has been around for ages now! Math.hypot(1,1); // 1.4142135623730951 (So has Math.SQRT2. I also forgot I already remembered and re-forgot that)
When I de-bloated my piece of the web, I noted that the largest asset I was serving on my blog was a local version of jQuery – coming in at some 70+ kilobytes – that “I still need to insert into the head of my page for historical reasons: 15 years ago I in-lined lots […]
You learn something new every day. Today I learned about insect reproductive systems, and also that document.designMode is a thing. Both seemed pretty interesting, but only the latter let’s you make any text on any web site “editable”. Open up the dev console and type document.designMode=”on”, and marvel as you can type over any text […]
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 […]
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 […]
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 […]
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.