So to add onto what I learned from this question I asked:
F# Records: Dangerous, only for limited use, or well used functionality?
This got me thinking about whether I should be using Types with methods or Records(?) AND methods. For example, this is a typical type I might make:
(* User Interaction Start *)
type UserInteraction public() =
member public x.CreatePassword(originalPassword) =
if String.IsNullOrEmpty originalPassword then
raise(new ArgumentException "CreatePassword: password is null or empty")
let hashUtility = new HashUtility();
hashUtility.CreateHash originalPassword
The problem I could see with this is there's a possibility that something within that UserInteraction type is mutable due that being allowed. Now with record types, as far as I understand, they are guaranteed to be immutable.
Would it be better design a module with methods that take in or return record types only or even go one step further with method chaining?