2nd October, 2022
“Quick look, Dynamic Island”
I’m still not taking notes. Let’s never speak of it again.
Finally, I have found a solution to the majority of my Quick Look plugins being broken since moving to an M1 Mac – Syntax Highlight. This is really well done, supporting loads of languages and is very configurable.
You can tell Active Record to not lazily load associations by default using strict loading (since Rails 6).
Sets the record to strict_loading mode. This will raise an error if the record tries to lazily load an association.
Via Thiago Massa.
I’ve been trying to revive a side project written in Elixir and Phoenix that I started two and a half years ago 😅 How time flies. It was barely an experiment but now I’m looking to actually make it work.
I decided to update Phoenix. A lot has changed, in particular with LiveView. The upgrade itself was easy, and everything was working afterwards with minimal changes, but I decided to try and bring all the defaults up-to-date too.
The best way I could think to do that was to install the latest Phoenix generator and generate a new application with the same name in a different directory. That let me diff the two directories to see what has changed in the code that the generator…generates. Porting the changes over then became fairly straight forward.
Fourble is a cool idea.
Fourble turns lists of .mp3 files into podcasts. Point it at some audio files hosted anywhere online, and it’ll turn them into a podcast feed which you can subscribe to and share.
Ruby just had a native immutable value object implementation merged 🥳
I downloaded and built Ruby
masterto have a play (which wasn’t as difficult as I had imagined after a small hiccup with needing to install
irb(main):001:0> Person = Data.define(:firstname, :lastname) => Person irb(main):002:0> Person.new (irb):2:in `initialize': missing keywords: :firstname, :lastname (ArgumentError) irb(main):003:0> person = Person.new(firstname: "Frodo", lastname: "Baggins") => #<data Person:...> irb(main):004:0> person.inspect => "#<data Person firstname=\"Frodo\", lastname=\"Baggins\">" irb(main):005:0> person.firstname => "Frodo" irb(main):006:0> person.firstname = "Bob" (irb):6:in `<main>': undefined method `firstname=' for #<data Person firstname="Frodo", lastname="Baggins"> (NoMethodError)
There have been various third party libraries to fulfill this need in past years, but I hope having something built-in will mean value objects are adopted more. Installing a third party gem will always have more resistance to use.
It looks like zverok has been working on this for 3 years 😮
I guess this will be in Ruby 3.2.