Hacker News new | ask | show | jobs
by bbzealot 1393 days ago
I don’t see your point.

DDD is not inherently tied to OOP: the whole strategical part isn’t about code at all, and the tactical part is applicable to FP as much as to OOP.

WRT design patterns, they exist in functional programming as well, they’re just different.

1 comments

DDD is not hightly coupled to OOP, the problem is that most popular books (red and blue one linked in Fowler's blog for example) were written in time when OOP was very popular and authors also used languages that propagates OOP. If the authors would used purely functional languages then people wouldn't assume it is about OOP.
Fair point, even though IMHO it's not that hard to apply the concepts from these books to a FP context.

Nowadays there are even resources about DDD specific to the FP world, such as Domain Modeling Made Functional by Scott Wlaschin [0].

[0] https://pragprog.com/titles/swdddf/domain-modeling-made-func...