Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What good patterns for a web framework are out there?

What are design patterns that would be useful for a web framework besides MVC, the Rails-induced frenzy? Not saying it's a bad thing, but it is now practically ubiquitous in web frameworks.

Ideally the pattern should make easier:

  • Separation of concerns
  • Modularity / reusability of code
  • Unit testing

What patterns fit the bill? Are there example of frameworks out that follow it?

like image 541
Confluence Avatar asked Jan 22 '23 08:01

Confluence


1 Answers

MVC is not a Rails-induced frenzy. It goes back to Smalltalk. You can check out the history in the GoF book as well, which pre-dates Rails.

I don't know about patterns beyond the GoF book, but I'd say that general ideas of layering (e.g., separate web, service, and persistence tiers) and decomposition apply regardless.

like image 154
duffymo Avatar answered Feb 15 '23 15:02

duffymo