|
|
|
|
|
by teknopaul
2670 days ago
|
|
Re"pulverise code into tiny functions with the goal of having code that consists only of assignments and function calls" You dont refactor so its "so small it becomes functional". You remove/refacor code with side effects where possible. So that part of the code becomes functional. It does not matter if a function is a lot of code or a little as long as it does not impact the world outside it. A small function that adds two numbers and as a side affect assigns some global state is to be avoided however small the function. "Fuctional programming" is not just about writing lots of functions |
|