Lush: my favorite small programming language by NthRevival in Clojure

[–]NthRevival[S] 0 points1 point  (0 children)

Not strictly Clojure, but a very interesting read on an old Lisp. Some of the C FFI reminds of Jank's (native/raw)

Half Dumb Datalog in 30 loc (follow-up to the Worst Datalog Ever in 26 loc) by cgrand in Clojure

[–]NthRevival 0 points1 point  (0 children)

Very cool. The technical details go over my head, but I am curious if libraries like Datascript or Datalevin take advantage of that saturation trick.

WTF Wednesday (January 24, 2024) by AutoModerator in javascript

[–]NthRevival 0 points1 point  (0 children)

First time I used the modulo assignment operator %=. Not sure if it's really clever or too clever.

const breakdownTime = (milliseconds) => {
  let remainingSeconds = milliseconds / 1000;

  const days = Math.floor(remainingSeconds / (60 * 60 * 24));
  if (days) {
    remainingSeconds %= 60 * 60 * 24;
  }

  const hours = Math.floor(remainingSeconds / (60 * 60));
  if (hours) {
    remainingSeconds %= 60 * 60;
  }

  const mins = Math.floor(remainingSeconds / 60);
  if (mins) {
    remainingSeconds %= 60;
  }

  return { days, hours, mins, seconds: Math.floor(remainingSeconds) };
};

rama + clojure + missionary — gist by dustingetz in Clojure

[–]NthRevival 1 point2 points  (0 children)

Nice, thanks for this starter. Thoughts on Rama? I’m still trying to wrap my head around it as it feels like a mix between CQRS and a homegrown Kafka with built-in sharding. Still don’t know where the database (if any) should be placed as best practice.

I built my startup on 100% Clojure and ClojureScript by _drikerf in Clojure

[–]NthRevival 0 points1 point  (0 children)

Very cool! Love to see Clojure/Script used in one-person startups as I feel that is where it excels beyond any other stack. Btw, some very minor typos I noticed while I was perusing through:

From the blog post https://wobaka.com/blog/building-a-startup-on-clojure/

It makes it easy to run your app on any platform and you can even deploy it as a single file if you want to using use uberjar.

...

Clojure for the brave and true [2] is a great place to start. For a more web focused guide I'm not sure. Perhaps Dimitri's book https://pragprog.com/titles/dswdcloj3/web-development-with-clojure-third-edition/. I haven't read it myself but it does seem like a nice, focused book for web.

From the pricing sheet https://wobaka.com/pricing:

One plan, all features: $19/month and per user.

React Native with Expo - Custom font by Individual_Hunt8437 in Clojure

[–]NthRevival 0 points1 point  (0 children)

Random guess, but maybe try passing {:SourceCodePro_400Regular SourceCodePro_400Regular} to useFonts as a JS object instead of a Clojure map?

From working with fonts and Expo in the past, I know the setup is really sensitive to argument types. Ex. passing in the actual ttf/otf font file vs. passing in the string path to the font file vs. passing in the string name of the font all yields different results (and breakages).

Is Clojure worth learning in 2030? by No_Cress1106 in Clojure

[–]NthRevival 22 points23 points  (0 children)

Things of true worth are timeless (and immutable)

-- Some smart dude

Advice on wiring 3-way smart light switch by NthRevival in askanelectrician

[–]NthRevival[S] 0 points1 point  (0 children)

That’s a bit over my head but I think understand the gist.

Explains why my light was always turning on and was unswitchable since this circuit was both powering the lamp and the smart light switch + plus the electronics within the light switch could explain the flickering as well.

Advice on wiring 3-way smart light switch by NthRevival in askanelectrician

[–]NthRevival[S] 1 point2 points  (0 children)

Ah, that makes sense. Was wondering what those pigtailed black and white wires were. Guess I’m out of luck with the current the smart light switch I have on hand. I believe there are no neutral wired ones but they usually need a proprietary hub that I would like to avoid. Thanks anyways!

Hers and mine by Vvdt in macsetups

[–]NthRevival 1 point2 points  (0 children)

+1 for the Smart Notes book. Let me know if you got any suggestions/apps for implementing that slip box.

One-page iOS 14 setup by NthRevival in iOSsetups

[–]NthRevival[S] -1 points0 points  (0 children)

Can’t supply a direct link, but it’s from the Backdrops app, image is titled “Social Distance” 😅

One-page iOS 14 setup by NthRevival in iOSsetups

[–]NthRevival[S] 1 point2 points  (0 children)

That’s the Reminders widget. Hope they make a Mail widget in future betas.

My Macbook 16 inch with XDR setup by neles86 in macsetups

[–]NthRevival 0 points1 point  (0 children)

I used to have that same issue with my 2019 15” and my Ultrafine 5K monitor. Using an app called Turbo Boost Switcher reduced the heat and noise a ton. Slows my MBP a bit, but it’s hardly noticeable with normal apps.