Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modern Rails application patterns and layers #66

Open
joshmfrankel opened this issue Sep 21, 2023 · 0 comments
Open

Modern Rails application patterns and layers #66

joshmfrankel opened this issue Sep 21, 2023 · 0 comments

Comments

@joshmfrankel
Copy link
Owner

joshmfrankel commented Sep 21, 2023

image

Request Layer

  • Middleware
  • Routing
  • Controller

View Layer

  • View - think of like a controller
  • Components
  • Stimulus Controllers
  • Strada - new

Business Layer

  • Policy - authorization logic for records and scopes (Pundit)
  • Service - Follows command pattern by performing an action with side-effect
  • Query - Follows query pattern by asking questions to return data
  • Presenter - Decorates a database object (todo: need better details here)
  • Jobs
  • Mailers

Data Layer

  • Model - How can we fit Entity and Repository into the Rails architecture?
  • Database

Advanced patterns

  • Adapters
  • Schemas
  • Serializers
  • Adapters
  • Transformers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant