Now that Kitten¹ is rather stable, I’ve decided to write some regression tests before refactoring to add class-based route/component support (in addition to the current—easy to get started with/use—function-based workflow).
I tried using Playwright but it’s quite heavy and not quite right for my needs (Kitten is more than just a server and I need control of it during testing). ~100 lines of code later, I have something that works well using tape and JSDOM :)
Just added a code breakdown for the Draw Together¹ Kitten² app to my blog post with the tutorial video:
https://ar.al/2024/03/26/draw-together/
Draw Together, in ~50 lines of code, is a real-time collaborative drawing tool on a 20×20 pixel grid where people can click to toggle the colour of each pixel.
(The full source and explanations fit the four screenshots on this post.)
¹ https://draw-together.small-web.org
² https://kitten.small-web.org
#Kitten #DrawTogether #web #design #dev #SmallWeb #WebSockets #StreamingHTML
Apologies if you’ve been unable to install Kitten* recently. Looks like there were a huge number of sessions created in a very short period of time, exhausting the memory on the tiny VPS server that serves the binaries. Might be AI crawlers (thanks, asshats). Looking into it and will add checks to session persistence to try and try and handle these sorts of attacks (because, really, that’s what they are) going forward.
Was just documenting the KittenMoji standard I use to Base256 encode your ed25519 secret key in Kitten.
The full alphabet:
🐵🐒🦍🦧🐶🐕🦮🐩🐺🦊🦝🐱🐈🦁🐯🐅
🐆🐴🧮🦄🦓🦌🦬🐮🐂🐃🐄🐷🐖🐗🐽🐏
🐑🐐🐪🐫🦙🦒🐘🦣🦏🦛🐭🐁🐀🐹🐰🐇
🎈🦫🦔🦇🐻🐨🐼🦥🦦🦨🦘🦡🐾🦃🎹🐓
🐣🐤🐥🐦🐧💕🦅🦆🦢🦉🦤🪶🦩🦚🦜🚲
🐊🐢🦎📚🐉🦕🦖🐳🐋🐬🦭🐟🐠🐡🦈🐙
🐚🐌🦋🐛🐜🐝🪲🐞🦗🎭🎁🧬🪱🦠💐🌸
🎠🌈🌹🧣🌺🌻🌼🌷🌱🪴🌲🌳🌴🌵🌾🌿
🎤🍀🍁🪺👽🍇🍈🍉🍊🍋🍌🍍🥭🍎🍏🍐
🍑🍒🍓🫐🥝🍅🫒🥥🥑🍆🥔🥕🌽🧸🫑🥒
🥬🥦🧄🧅🍄🥜🌰🍞🥐🥖💩🥨🥯🥞🧇🧀
🎶🏸🎾🎨🍔🔭🍕🌭🥪🌮🌯😸📷🌜🥚🚂
🛼🚁👾👻🥗🍿🧩🖖🥫🎸🍘🍙🍚🃏🍜🍝
🍠🍢🍣🍤🍥🥮🍡🥟🥠🩰🦀🦞🦐🦑🎡🍦
🍧🍨🍩🍪🎂🍰🧁🥧🍫🍬🍭🍮🎓🍼🎮🛹
🫖🌍🌎🌏🧭🌠🪐🪀🧵🧶🧋🎉🪁🙈🙉🙊
Maybe I’ll make a limited-edition poster of it sometime :)
Kitten¹ update
I just added a new htmx header to #WebSocket messages in Kitten that contains the actual event type (name) that triggered the message.
This is useful, for example, if your trigger is a horizontal swipe and you need to differentiate between whether it was a swipe left or a swipe right that caused it.
Upstream issue: https://github.com/bigskysoftware/htmx-extensions/issues/74
Upstream merge request: https://github.com/aral/htmx-extensions/commit/359da12563fd0ef6709d801972f98ba1ab61c302
Enjoy!
:kitten: 💕
As a fun little exercise, I decided to port Miuki Miu’s (Elizabet Oliveira’s) adorable React Kawaii¹ to Kitten².
Going to write a blog post about the experience but, in the meanwhile, if you want to play with the cute little characters, here you go:
https://kitten-kawaii.small-web.org
And here’s the source code:
https://codeberg.org/aral/kitten-kawaii/
Things to try: the back and forward buttons ;)
¹ https://react-kawaii.vercel.app
² https://kitten.small-web.org
#Kitten #SmallWeb #React #BigWeb #porting #experiment #kawaii
076萌SNS is a social network, courtesy of 076. It runs on GNU social, version 2.0.2-beta0, available under the GNU Affero General Public License.
All 076萌SNS content and data are available under the Creative Commons Attribution 3.0 license.