Tuesday, January 25, 2022
Monday, January 24, 2022
Thursday, January 20, 2022
Tuesday, January 18, 2022
Sunday, January 16, 2022
Friday, January 14, 2022
Tuesday, January 11, 2022
Rails - Counter Cache
Counter Cache
https://rubyinrails.com/2019/04/10/rails-counter-cache-associations/
https://scoutapm.com/blog/how-to-start-using-counter-caches-in-rails
For many-many association:
https://coderwall.com/p/muvy9w/forget-counter-cache-for-many-to-many-associations-in-rails
https://stackoverflow.com/questions/5256897/counter-cache-with-has-many-through
Monday, January 10, 2022
Saturday, January 8, 2022
Rails related: Concerns, Module-method extraction Vs Class-based extraction, Concerning module
1) Single-use Modules are probably better off as Classes as per the below article.
https://www.cloudbees.com/blog/when-to-be-concerned-about-concerns
By and large, maintainers tend to agree that smaller composable classes are the best way to isolate code and keep things clean.
....
....
I'm not saying that you need to go out and refactor all your single-use modules into classes. I am saying if you find yourself reaching to do a module-method extraction, stop. Consider what road you're starting down and these lessons I've shared. What would a class-based extraction look like instead?
2) https://blog.appsignal.com/2020/09/16/rails-concers-to-concern-or-not-to-concern.html
3) https://api.rubyonrails.org/v5.0/classes/Module/Concerning.html
4) https://scoutapm.com/blog/rails-concerns - sort of consolidates content from the above articles
Friday, January 7, 2022
Thursday, January 6, 2022
Tuesday, January 4, 2022
Ruby/Rails related sites
https://rubyflow.com/ - Links to articles
https://www.speedshop.co/blog/ - Rails performance blog
Sunday, January 2, 2022
Draft Pull Requests
https://software.rajivprab.com/2021/12/26/our-engineering-principles-and-best-practices/
Draft Pull-Requests
For each pull-request, first create a draft pull-request, demonstrating the proposed implementation at a high level. Use TODOs and placeholders to indicate which classes/methods you will be touching. Send it off for review and then immediately start working on the actual code and tests.
This mitigates the amount of wasted effort, if your reviewer then suggests a completely different way of implementing things. Once your reviewer approves the draft, link to it in your pull-request, to make sure everyone knows what was already discussed and agreed on.
Saturday, January 1, 2022
Followers
Blog Archive
-
▼
2022
(200)
-
▼
January
(27)
- SwiftUI - Quick Start & Projects
- Elixir Desktop
- CSS - Absolute Position examples
- Hybrid iOS apps with Turbo
- Conditional Rendering With Turbo Stream Broadcasts
- Rails & Hotwire - Good articles on www.colby.so
- Rails: Good article on Turbo Streams
- info.plist in Xcode 13
- Rails - Counter Cache
- CSS - container queries polyfill
- Rails related: Concerns, Module-method extraction ...
- Ruby - differences between Proc and Lambda
- Is module_function really the same as extend self?
- Rails related - Performance improvement
- Building a Rails App With Multiple Subdomains
- Building a Multi-Tenant Ruby-on-Rails app
- Rails - How to implement Routes for Many-to-Many
- CSS Transitions: Here's How You Learn Most Fundame...
- Rails: Hotwire in the real world
- Ruby/Rails related sites
- A Case for Outside In Design – Sandro Mancuso
- Draft Pull Requests
- CORS related
- Computer Networking Introduction - Ethernet and IP...
- Container Networking Is Simple!
- SwiftUI Videos
- SwiftUI Tutorial - Advanced ScrollView - Snap Inte...
-
▼
January
(27)