I am working on a FAKE project using F# - I am not fluent in F# or functional first programming, and am mostly doing front-end formatting. I am trying to set the color of an item based off of a class variable assigned to it. I am having issues converting this into string or using it in an if statement. I know its a long-shot, but are there any F# developers out there who might have experience in this area?
the class:
type State =
| New
| Open
| Closed
| Archived
the item to be recolored:
td [ ClassName "text-center" ] [ statusTag appt.state ]
I am primarily a C# developer, so the way that F# does things is very foreign. Normally i would just create an if statement and plug the state into it with a .ToString(), then use that to restyle but I am stumped as to how to go about it using F#. Any help would be greatly appreciated.