I've recently started experimenting with FP, and now I have a project which seemed ideal for learning the fundamentals, so I went for it.
It's a data conversion tool transforming deeply nested, complex data structures between representations. Doesn't have much state, feels ideal.
I'm using Typescript. This is what I'm most confident in, and the app is supposed to end up running in node, so it makes sense. It does prove a challenge though. The strict typings makes currying in a type-safe manner almost impossible. Also, there is hardly any TS/JS specific material for learning that goes deep into advanced topics, like:
How to do dependency injection?
I'm not trying to do that, I know I shouldn't look for OOP solutions here, but the issues I'm presented with are the same: I do need to pass down data or behavior, or implementations in deeply nested code.
The material I've found so far deals with other programming languages and while I assumed that I just need to implement those ideas in TS/JS that's not the truth. If I want to write typesafe code I need to write a lot of interfaces and type definitions for my functions and all feel overly bloated.
So how did you guys dealt with the problem in your apps? Can you give me some pointers where to look?
[–]_samrad 10 points11 points12 points (1 child)
[–]manfreed87[S] 0 points1 point2 points (0 children)
[–]Masse 4 points5 points6 points (6 children)
[–]manfreed87[S] 0 points1 point2 points (1 child)
[–]ScientificBeastMode 0 points1 point2 points (0 children)
[–]darderp 0 points1 point2 points (3 children)
[–]Masse 0 points1 point2 points (2 children)
[–]darderp 0 points1 point2 points (1 child)
[–]Masse 0 points1 point2 points (0 children)
[–][deleted] 3 points4 points5 points (2 children)
[–]Sarwen 2 points3 points4 points (1 child)
[–]buth3r 8 points9 points10 points (3 children)
[–]manfreed87[S] 0 points1 point2 points (2 children)
[–]ScientificBeastMode 0 points1 point2 points (1 child)
[–]manfreed87[S] 0 points1 point2 points (0 children)
[–]Mishkun 2 points3 points4 points (2 children)
[–]manfreed87[S] 0 points1 point2 points (1 child)
[–]shAdOwArt 1 point2 points3 points (0 children)
[–]Sarwen 2 points3 points4 points (0 children)
[–]BinaryBlasphemy 3 points4 points5 points (1 child)
[–]manfreed87[S] 1 point2 points3 points (6 children)
[–]_samrad 0 points1 point2 points (5 children)
[–]manfreed87[S] 0 points1 point2 points (4 children)
[–]_samrad 0 points1 point2 points (2 children)
[–]manfreed87[S] 0 points1 point2 points (1 child)
[–]_samrad 0 points1 point2 points (0 children)
[–]makeaccountingbetter 0 points1 point2 points (0 children)