5 ms·
Two areas where F# might be preferable: - You can use reflection to generate encoders and decoders. These can be mixed and matched with hand written encoders a
by pharmakom 5y ago
Two areas where F# might be preferable:
- You can use reflection to generate encoders and decoders. These can be mixed and matched with hand written encoders and decoders.
- You can just throw an exception when unpacking a result or maybe into a value
- You can use “?” and “!!” operators to tell the compiler that the type is correct when working with dynamic objects
- cies 5y ago> F# might be preferable For getting something live quick: yes. But the learning experience of writing some pure-FP code is destroyed by "just throw an exception" and "use “?” and “!!” operators to tell the compiler that the type is correct"
- nagasadhu 5y agoYou don't have to use exceptions and other operators with side effects if you don't want to. You can have a pure FP experience with fable and F#. The OP was just mentioning that these escape hatches are available if you need them.
- pharmakom 5y agoYes I think they can be removed with linting rules once you are ready to hit production.