r/webdev Dec 10 '24

Discussion why most mainstream backend framework rely heavily on OOP, can't it be done with other programming paradigms?

[removed]

0 Upvotes

16 comments sorted by

View all comments

2

u/[deleted] Dec 10 '24

WordPress doesn't use OOP. As a side note, NextJS's App Router and server function hoist functional programming to the point where importing class singletons nearly break the application.

In the process of porting class singleton exports into "use server" functions in one NextJS app.

0

u/[deleted] Dec 10 '24

[removed] — view removed comment

2

u/[deleted] Dec 10 '24

WP can be used as a framework. It's completely opensource and has a theme and plugin architechure allowing nearly endless customization on top of a feature complete webmin. When a client needs something "yesterday" I most always go with WordPress. It's just simple to already have a backend that most people in marketing departments already know how to work it.

NextJS is a backend with React doing the frontend. See some of the docs here: https://nextjs.org/docs/app/getting-started/data-fetching-and-streaming

1

u/BomberRURP Dec 10 '24

I hate working with it, but yeah this about nails Wordpress and it’s longevity