2 ms·
I don't see any credentials mentioned in your profile, which means we're all random guys on the internet :) With reference to the article, it builds on top of
by flowerlad 5y ago
I don't see any credentials mentioned in your profile, which means we're all random guys on the internet :)
With reference to the article, it builds on top of authoritative articles (see References section at the bottom), so you don't have to take anything at face value!
You're right, I am indeed saying that verifiability is intrinsically related to purity. The concept of pure functions is at the core of FP. You take that core away and you no longer have the right to call your code FP.
Why is it important to label something as FP in any case? React is useful even if it is not functional. What I am opposed to is misappropriating the "FP" label for marketing purposes, by the React team.
- lhorie 5y ago> The concept of pure functions is at the core of FP. Only in the subset that you consider canon, not generically for all FP. Wikipedia is quite authoritative, FWIW. I agree that the React team has made some flat out wrong claims (e.g. incorrectly calling hooks pure at one point), but you're engaging in exactly the same sort of "marketing" you dislike, by biasedly claiming your specific flavor of FP is the "real deal", when in reality there are many different cohorts within the larger FP community that prioritize different things. If I had to criticize your purity-centric flavor, I'd say it's very reminiscent of the height of the OOP craze, with algebraic terminology elitism being similar to the one surrounding GoF pattern terminology. Also similar are the grandiose theories of maintainability, and the dichotomy between what loudmouths preach and what code in the wild looks like. People log things from .map callbacks. They don't grok monads. It seems entirely arbitrary to me to deny the functionalness of some code based on some technicality (case in point, do you avoid promises and do you Object.freeze(Object.create(o)) all your objects?) IMHO, there's no point defending some notion of an FP brand. Looking around this thread, you can see that people already view React's hot take on FP as problematic. Same goes for general perception of the more elitist corners of the FP community.
- flowerlad 5y agoI can agree with most of what you are saying. My alarm stems from the fact that a lot of developers' understanding of FP these days comes from their React experience (which they mistakenly believe is FP) and a lot of these developers also believe that OOP is now obsolete... all based on their mistaken understanding of what FP is. I think there is a need for course correction here.