Module
Polyform.Field.Generic  
- Package
 - purescript-polyform
 - Repository
 - paluh/purescript-polyform
 
#SingleChoice Source
class SingleChoice choice  whereThis type class provides basic way to transform simple sum type
(constructors without args are only allowed) into: Validation and
choices array which can be used in Choice record.
Members
choiceImpl :: choice -> StringchoicesImpl :: Proxy choice -> List (Tuple String choice)
Instances
(SingleChoice a, SingleChoice b) => SingleChoice (Sum a b)(IsSymbol name) => SingleChoice (Constructor name NoArguments)
#choice Source
choice :: forall choiceRep choice. Generic choice choiceRep => SingleChoice choiceRep => choice -> String#choiceParser Source
choiceParser :: forall m choiceRep a. Monad m => Generic a choiceRep => SingleChoice choiceRep => Proxy a -> Validation m String String a#MultiChoice Source
class MultiChoice c (c' :: Row Type) | c -> c' whereMembers
multiChoiceParserImpl :: Proxy c -> Array String -> { remaining :: Array String, result :: { checkChoice :: c -> Boolean, product :: Record c' } }
Instances
(IsSymbol name, RowCons name Boolean () row, RowLacks name ()) => MultiChoice (Constructor name NoArguments) row(IsSymbol name, MultiChoice tail tailRow, RowCons name Boolean tailRow row, RowLacks name tailRow) => MultiChoice (Sum (Constructor name NoArguments) tail) row
#multiChoiceParser Source
multiChoiceParser :: forall m row choiceRep a. Monad m => Generic a choiceRep => MultiChoice choiceRep row => Proxy a -> Validation m (Array String) (Array String) { checkChoice :: a -> Boolean, product :: Record row }- Modules
 - Polyform.
Field  - Polyform.
Field. Generic  - Polyform.
Field. Generic. Option  - Polyform.
Field. Html5  - Polyform.
Field. Validation. Combinators  - Polyform.
Form. Component  - Polyform.
Input. Foreign  - Polyform.
Input. Http  - Polyform.
Input. Interpret  - Polyform.
Input. Interpret. Http  - Polyform.
Input. Interpret. Record  - Polyform.
Input. Interpret. Validation  - Polyform.
Validation  - Polyform.
Validation. Par  
This function doesn't report invalid values (hence Unit as error type) It only marks valid ones currently...