Become a sponsor to Kasper Timm Hansen
Hey, I'm Kasper — I've served on the Rails core team for 6 years, merged 1000s of contributor PRs on rails/rails and I've made horribly great puns on Twitter.
Your sponsorship goes toward more exploratory work and experiments
I'm trying out different ways of extending and expressing Domain Models in Ruby and Rails. Here's what I've come up with so far.
Here's extending our model layer with more descriptive vibes:
- https://github.com/kaspth/active_record-associated_object — Associate a Ruby PORO with an Active Record class and have it quack like one.
- https://github.com/kaspth/active_record-ingress — Pass control of Active Record methods to a dedicated object, though really it's about having a conventional place for operations in your app.
Here's a Ruby extension to help define initializers https://github.com/kaspth/struct-initializer
I've added https://github.com/kaspth/conventional_extensions as an alternative way to extend your domain model instead of ActiveSupport::Concern
.
https://github.com/kaspth/action_controller-stashed_redirects is some syntactic sugar on top of redirect_to
to help with cross-controller communication.
For the future, I'm curious about exploring more extensions and changes to Rails' view layer. It's stayed the same for a decade and nobody's really touched it yet. Thank you for considering me for your sponsorship ✨
Featured work
-
kaspth/active_record-associated_object
Extract Collaborator Objects from your Active Records, a new concept called Associated Objects
Ruby 259 -
kaspth/oaken
A fresh blended alternative to Fixtures & FactoryBot for dev and test data.
Ruby 189 -
kaspth/active_job-performs
ActiveJob::Performs adds the `performs` macro to set up jobs by convention.
Ruby 147 -
kaspth/action_controller-stashed_redirects
Stash a redirect to execute a controller flow within another and return to the original flow later.
Ruby 57 -
bullet-train-co/nice_partials
A little bit of magic to make partials perfect for components.
Ruby 290 -
kaspth/conventional_extensions
ConventionalExtensions sets up a file naming convention to extend your domain model
Ruby 71