3 ms·
Re: DDD and business logic, I’d recommend reading https://dev.37signals.com/vanilla-rails-is-plenty/ https://dev.37signals.com/vanilla-rails-is-plenty/
by lylo 3y ago
Re: DDD and business logic, I’d recommend reading https://dev.37signals.com/vanilla-rails-is-plenty/ https://dev.37signals.com/vanilla-rails-is-plenty/
- berkes 3y agoI've read that and tried it. I hate it. This recent article has some alternatives https://blog.appsignal.com/2023/05/10/organize-business-logic-in-your-ruby-on-rails-application.html https://blog.appsignal.com/2023/05/10/organize-business-logi... Their main argument against the first piece is: > One problem with fat models is that unless you are really disciplined in your code hygiene, they can tend towards an assortment of code smells And I wholeheartedly agree. With the addition that "code hygiene" if not enforced or encouraged, is always one of the first victims under stress. And every (successful) project will see such stress. With Rails you have to spend extra effort to keep doing "the right thing", whereas is should cost cost less effort to do that, and extra effort to "do the bad thing".