Short Ruby Newsletter

Share this post

πŸ’» Short Ruby News - The Code Edition #39

newsletter.shortruby.com

Discover more from Short Ruby Newsletter

A Monday summary of the articles, discussions, and news from the Ruby community
Over 4,000 subscribers
Continue reading
Sign in

πŸ’» Short Ruby News - The Code Edition #39

Briefly about everything happening in Ruby world - week 16 of 2023

Lucian Ghinda
Apr 25, 2023
3
Share this post

πŸ’» Short Ruby News - The Code Edition #39

newsletter.shortruby.com
Share

You can jump directly to a section:

πŸ‘‰Β All about Code and Ruby

🧰 Gems, Libraries, and Updates

🀝 Related (but not Ruby-specific)

The content section that includes videos, talks, screencasts, podcasts, newsletters, and articles can now be found in The Content Edition (and sent in a separate email).

For just a small amount of $1.5 per week (only $6.5 a month), you can become a valued paid subscriber and actively support the thriving Ruby community we all love!

By contributing, you'll be playing a pivotal role in fostering growth and maintaining the high standards of ShortRuby for everyone to enjoy.

Support the newsletter for ~1.5$/week


πŸ‘‰ All about Code and Ruby

πŸ‘‰Nate Hopkins shared a sample code and a gist about ActiveJob as Service Worker

Source: @hopsoft

He added:

Source: @hopsoft

There is a good discussion in the replies to Nate proposal. I picked here a couple of the replies:

Source: @palkan_tula
Source: @palkan_tula
Source: @mtantawy

πŸ‘‰ Ingemar shared how to run your gem documentation server:

Source: @ingemar@ruby.social

πŸ‘‰ Okura Masafumi shared a gist about Tell me if this module is included by the same class more than once

Source: @okuramasafumi@ruby.social
Source: https://gist.github.com/okuramasafumi

πŸ‘‰ Greg Navis shared a thread about Enumerable#all? Here is one of the posts shared:

Source: @gregnavis

πŸ‘‰Nate Berkopec shared a tip about using preload and eager_load

Source: @nateberkopec@ruby.social

πŸ‘‰Postmodern asked about suggestions to split a hash into a value for a key and the rest of the hash:

Source: @postmodern@ruby.social

There are some good replies there, here are three of the proposed solutions:

  • Jesse Cooke proposed the following solution based on the article Everything You Need to Know About Destructuring in Ruby 3 suggested by Rachael Ludwick

Source: @jc00ke@ruby.social
  • Stephann V proposed the following direct solution:

Source: @ste@ruby.social

πŸ‘‰Dr Nic Williams asked for recommendations for building an admin section:

Source: @drnic

Here are some recommendations:

Source: @strzibnyj
Source: @sdglhm
Source: @ilrock__
Source: @adrianthedev

πŸ‘‰ Greg Navis shared a thread about counting objects with Enumerable. Here is one of the tips shared in Greg thread:

Source: @gregnavis

πŸ‘‰Brad Gessler shared an excellent comparison of components and partials in a thread where he presented an article about Component driven development on Rails with Phlex

Source: @bradgessler

πŸ‘‰ u/A_little_rose/ presented a dilemma about how to work with class instance variables

Source: /u/A_little_rose
Source: /u/A_little_rose

You should read the proposed solution and the discussions on /r/ruby about this. Here is one of the answers:

Source: /u/OlivarTheLagomorph

πŸ‘‰ Greg Navis shared a thread about extracting file name, directory name and extension from a file path:

Source: @gregnavis

πŸ‘‰Andrew Mason asked about recommended gems of all time:

Source: @andrewmcodes

Andrew announced they would write an article and share it on RubyForAll thus, I will not compile here the list of recommended gems from the replies.

πŸ‘‰Maciej Mensfeld announced support for iterating through Kafka topics with Iterator API - Karafka framework documentation

Source: @maciejmensfeld

πŸ‘‰Vincent Rolea shared a short thread about how simple it is to discard a modal with Turbo:

πŸ‘‰Andrew Mason asked a question about productivity hacks:

Here are some suggestions:

  • Listening to music (genre suggested rap, dubstep

  • Using an app like Centerer app

Source: @nodunayo
Source: @itsAL83738725

πŸ‘‰Matt Swanson shared a piece of code showing how to use the ~* postgres operator:

Source: @_swanson

πŸ‘‰Robby Russell asked about recommendations for site generators that build pages for a collection of records from RESTful API:

Source: @robbyrussell

Here are some recommendations:

  • sitepress.cc - that can be embedded in Rails

  • bridgetownrb.com - that has this page about HTTP Requests and the Resource Builder

  • there is an entire list of Static Site Generators at Awesome Ruby repo

πŸ‘‰ u/Plastic_Magician_420 shared the following answer to a question if Ruby is slow:

Source: /u/Plastic_Magician_420

🀞 I imagine that if you have read so far, you find value in this newsletter.

Short Ruby Newsletter is a reader-supported publication. To receive new posts and support my work, consider becoming a free or paid subscriber.


🧰 Gems, Libraries, and Updates

🧰 Avo announced a new release v2.30.2 Read the changelog

Source: https://github.com/avo-hq/avo/releases/tag/v2.30.2

🧰 Joel Drapper announced they released version 1.0 of phlex-rails. Read the changelog

Source: @joeldrapper@ruby.social

🧰Karl Oscar Weber announced the release of version 3.0 (and small updates v.3.0.1 and v.3.0.2) for Camping. Read the release notes for v3.0

Source: https://github.com/camping/camping/releases/tag/3.0

🧰 Xavier Noria announced a new release of zeitwerk: Efficient and thread-safe code loader for Ruby. Read the commit here

Source: https://github.com/fxn/zeitwerk#for_gem_extension

🧰 Justin Searls announced the release of version 1.28.0 of standardrb/standard gem:

Source: https://github.com/standardrb/standard/blob/main/CHANGELOG.md#1280

🧰 Marco Roth announced a new releasee of phlexing: Release v0.5.0 · marcoroth/phlexing

Source: https://github.com/marcoroth/phlexing/releases/tag/v0.5.0

🧰 Koichi Ito announced the release of v0.6.0 for tmm1/test-queue (a parallel test runner specifically optimized for CI environments)

🧰 Ronin Rb announced the plan for Phase 2 | Ronin

Source: https://ronin-rb.dev/blog/2023/04/16/announcing-phase-2.html

🧰 Rails Links shared a repo from thoughbot containing thoughtbot/hotwire-example-template: A collection of branches that transmit HTML over the wire

Source: https://github.com/thoughtbot/hotwire-example-template

🧰 Ruby On Mac shared that their software can now help to install Ruby < 2.5.9 on Apple Silicon

Source: @rubyonmac

🧰 Eric Berry shared a new gem they discovered called Boxcars AI:

Source: https://github.com/BoxcarsAI/boxcars

🧰Nejdet Kadir announced a new gem nejdetkadir/safe_poller: SafePoller is a Ruby gem that provides a safe and reliable way to perform periodic polling operations in multi-threaded environments

Source: https://github.com/nejdetkadir/safe_poller

🧰 Igor Kasyanchuk published a new gem called lazy_value about:

Source: https://github.com/railsjazz/lazy_value

Please consider becoming a paid subscriber to support this newsletter for just $1.5/week ($6.5/month). Your contribution aids growth and maintains the quality of ShortRuby for everybody:

Support the newsletter for ~1.5$/week

If you consider upgrading and want more information, please read Why to subscribe to paid


🀝 Related (but not Ruby-specific)

🀝Kevin Murphy shared a new feature of headless chrome Read more here

Source: @kevin_j_m@ruby.social

From the Chrome announcement

Source: developer.chrome.com

🀝Kent Beck shared about AI:

Source: @KentBeck

You might want to consider reading the two articles Kent wrote as a follow-up to this tweet: 90% of My Skills Are Now Worth $0 and More What, Less How

🀝 Tobias Petry.Sql shared a gist with over 1000+ PostgreSQL EXTENSIONs

Source: https://gist.github.com/joelonsql

🀝Paul shared a piece of knowledge from Uncle Bob about naming:

Source: @pdobb

🀝Gustavo Valenzuela shared a bash code for opening a remote repo with branch param from terminal:

Source: @GV1180

You can read The Content Edition if you want to discover the content created in Ruby World in week 16 of 2023:

Read the content edition


Please consider becoming a paid subscriber to support this newsletter for just $1.5/week ($6.5/month). Your contribution aids growth and maintains the quality of ShortRuby for everybody:

Support the newsletter for ~1.5$/week

If you consider upgrading and want more information, please read Why to subscribe to paid

3
Share this post

πŸ’» Short Ruby News - The Code Edition #39

newsletter.shortruby.com
Share
Previous
Next
Comments
Top
New
Community

No posts

Ready for more?

Β© 2023 Lucian Ghinda
Privacy βˆ™ Terms βˆ™ Collection notice
Start WritingGet the app
Substack is the home for great writing