-
I spent my last 2 weekends and weekday nights building a #TypeScript RPC library… only to just find out #tRPC exists and does exactly what I was building. Ooof.
-
Looking at #WebDev practices in the wild is a ride. Trying to #scrape websites, just looking at headers I've seen:
- Divs with id=header or id=site-header
- Multiple header elements with duplicated logos etc., changing which one is visible with JavaScript based on screen size
- Divs with absolutely no way to identify that it's the header, just CSS to put it at the top of the page
- A search form that is visually positioned in the header but is actually outside the header in the DOM -
Okay, I'm coming out of my libheif rabbithole with a new #NodeJS package: libheif-node-dy
It's a native module for #HEIF / #HEIC image decoding. Compared to the popular heic-decode, it's 3 to 5 times faster. It's dynamically linked against libheif for good measure, to completely make sure LGPL dynamic linking rule is satisfied.
This does mean you have to separately install libheif, but libheif is widely available in all distros so it shouldn't be hard to get.
-
Question on #licenses: Take an #LGPL licensed library written in C, compile it to JavaScript with #emscripten, and bundle it into a JavaScript app. The JavaScript app has to be LGPL licensed because the dynamic linking exception doesn't apply.
Same LGPL library, build a #NodeAPI module that statically links against it, and use that in a JavaScript app. The NodeAPI code would be LGPL'ed since it's statically linked, but would the #JavaScript code be fine since node loads the module dynamically?
-
Rewrote #BulgurCloud's frontend with #NextJS, moving away from #Expo & #ReactNativeWeb. React native features like native animations, data storage, or fast refresh are not available on the web, you have to write a lot of code twice so DX was not great. Also moved from a component library to #TailwindCSS & #DaisyUI
This means no native mobile apps, but #Tauri is great and mobile support is coming soon.
This also cut down the bundle size to one third of what it was before!
-
People sometimes shit on web development, but it's crazy how fast you can build with modern web.
I had an idea around reading product labels from images on a phone. So I grabbed the #SvelteKit template, added #TailwindCSS and #TesseractOCR, and put together with an input type="file". Then I used bore.pub to connect it to my phone and boom, I can take a photo on my phone and have text OCRed with one button. Built in under an hour.
-
Ever needed a quick #httpServer to serve up some local files?
I always use the basic python built-in module (http.server), but it has a few limitations like not being able to turn off CORS protection.
But I just found this project, which supports that and also has a few cool features like rendering markdown files and basic HTTP auth.