I would like to create an in depth technical blog post about the code structure of the Social fellowship app for Roots Elementary. There are many interesting pattern that are happening that are not something covered in the curriculum. The one I would like to focus on is Single Table Inheritence and Controller Inheritance (Super Controllers) and the benefits on abstraction
Part 1:
I want to focus on what it is, what it isnt' and why the app chose this unconventional rails pattern
Part 2:
Benefits. How it drys up code, how it makes CRUDing like resources super quick. I would like to show some code snippets here that can speak toward what it is.
Further, I want to show methods that are musts to get this up and running.
Part 3:
Lastly, I want to talk about the drawbacks I found jumping into a codebase with this pattern. Problems I have run into doing it on my own for my rails engine project, and comparing them to this more professional app. Some of these drawbacks include
-
onboarding
-
readability
-
bug fixing
-
scaling
Conclusion:
I really enjoy this pattern although it seems to break a lot of "rules" we've come to known. I would like to detail those rules and compare them to what is happening with this app.
Overall, I want to expose a pattern that is a bit more advanced that many new rails devs have not come across, and may be interested in knowing about.
More resources include