Google Gemini and AI Studio Launch

While it feels like just yesterday I first blogged about Google’s PaLM APIs and MakerSuite, it was actually over two months ago, and of course, GenAI offerings are iterating and improving at lightning speed. In the past week, Google has announced Gemini, their new generative AI model. Naturally, I was curious about the API aspect of this and took a quick look. MakerSuite rebranded as AI Studio # First off, the web UI (which I reviewed back in my first post) has been renamed to the generic and boring, but probably more enterprise and appropriate, AI Studio. Along with that, when creating new prompts, it will default to use Gemini models. (You can still select PaLM if you want.) Another change…... more →
Posted in: JavaScript

The Twelve (Generative) Days of Christmas

I tend to have a lot of silly ideas. Not useful ideas. Not good ideas. Silly ideas. Randomly yesterday I was thinking about the Twelve Days of Christmas song. If you aren’t familiar with it, it starts off with a gift for one day, then repeats and adds a second day, and so on and so on. The gifts are: partridge in a pear treetwo turtle dovesthree French hensfour calling birdsfive gold ringssix geese a-layingseven swans a-swimmingeight maids a-milkingnine ladies dancingten lords a-leapingeleven pipers pipingtwelve drummers drumming I thought – what if I took each of these phrases and dropped them into an AI image generator? I did, and the results were… kinda fun. Before I show... more →
Posted in: JavaScript

Awesome Netlify Updates

For about two months now I’ve had on my queue to write about some of the incredibly cool updates Netlify has released but I just didn’t have the time. I’ve been hosting this blog on Netlify for a few years now and have been incredibly happy with the platform, but the updates the past two months have been both surprising and just really freaking cool. Here’s a quick look at what impressed me. As a quick aside, this isn’t necessarily everything announced recently and you can take a look yourself at their blog for more changes. Caching Improvements # This is an area I haven’t really done much in – both on my site or elsewhere. I generally let Netlify worry... more →
Posted in: JavaScript

Adding Music Previews to My Now Page

About two months or so ago I added a Now page to my site. It shows my current reading list, my last watched movies, my Untappd beer check-ins, and my most recent Spotify tracks. You can see that part here: When I built it, I used a Pipedream workflow to wrap calls to Spotify’s API. My Pipedream workflow gets my most recent tracks, slims down the data quite a bit, and returns just what I need. I use some client-side code to hit that endpoint and then render it out on the Now page. (I also use a bit of caching with LocalStorage such that the endpoint is only hit every ten minutes.) Currently, when rendering each track, I link to its URL and Spotify users can listen to the track completely.... more →
Posted in: JavaScript

How to Play Grand Poo World 3

The underground world of creating and streaming Super Mario World-based ROM hacks continues to gain popularity. This popularity is a tribute to the creativity of gamers and the quality of the original 30 year old video game’s mechanics. Over the past decade, incredible ROM hacks like Grand Poo World 1 and 2, Invictus, and Dram World have brought joy (and horror) to the Mario community. Sure, Nintendo released Mario Maker and Mario Maker 2, but I love SMW Central patches because they allow all of us to create, much like open source. The most anticipated hack in years, Grand Poo World 3, was just released and is taking the Super Mario World community by storm. You cannot, however, just download... more →
Posted in: JavaScript

Using IndexedDB with Alpine.js

A lot of my "x with Alpine" blog posts end up being, well, nothing special. That’s a good thing I suppose as it really helps highlight how simple Alpine.js is. (Note, I go back and forth between including the ".js" when referring to Alpine. I should be more consistent I suppose. On one hand, Alpine.js is the formal name, but Alpine just feels simpler.) That being said, the impetus for this post was to get something basic done before I built something a bit more complex. So if you wish to TLDR – it just works, visit my CodePen for the full source, and come back for the next post. If you’re still curious, keep on reading. IndexedDB – Vanilla or Library?... more →
Posted in: JavaScript

Adding Simple Routing to Cloudflare Workers

I’ve been "playing" with serverless for years now, but honestly still feel new to it. When it comes to organization in a project that uses serverless functions, I’ve typically tried to build one function per operation. So for example, if I had a need to get a list of cats, I’d have one function. If I had a need to get information about a cat based on an identifier, I’d probably build a second one. That being said, I recently came across an example Cloudflare function that did something cool – it used a router, specifically the very lightweight itty-router. Let me share an example of how it works. What is a Router? # So I kinda assume most folks know what... more →
Posted in: JavaScript

A Tip for Properly Handling Loading States in Web Apps

This isn’t something I was going to blog about, but after seeing the same issue a few times recently (although to be fair, last in a mobile game), I thought I’d share it with my audience. I apologize if the title isn’t the best as it was a hard issue to describe, so let me begin by demonstrating the problem, and then the (hopefully) obvious solution. Loading Data # Here’s a super simple example of a web page that loads some data from the API. In this case, it’s the Star Wars API which, unfortunately, has been pretty slow recently. On the flip side, that helps illustrate that issue. The HTML is just an h2 and an empty ul and the JavaScript is fairly simple: document.addEventListener('DOMContentLoaded',... more →
Posted in: JavaScript
1 5 6 7 8 9 77