reflex-dom-core-0.8.1.0: Functional Reactive Web Apps with Reflex

Safe HaskellNone
LanguageHaskell98

Reflex.Dom.Xhr.FormData

Synopsis

Documentation

postForms Source #

Arguments

:: (IsBlob blob, MonadJSM (Performable m), PerformEvent t m, TriggerEvent t m, Traversable f) 
=> Text

The target url

-> Event t (f (Map Text (FormValue blob)))

Maps of text keys and values that will be sent as FormData

-> m (Event t (f XhrResponse)) 

Performs a POST request with the provided FormData payload

postForms' Source #

Arguments

:: (IsBlob blob, MonadJSM (Performable m), PerformEvent t m, TriggerEvent t m, Traversable f) 
=> Text

The target url

-> XhrRequestConfig a 
-> Event t (f (Map Text (FormValue blob)))

Maps of text keys and values that will be sent as FormData

-> m (Event t (f XhrResponse)) 

Like postForms but doesn't use a default XhrRequestConfig, so a custom one can be provided.

data FormValue blob Source #

A FormData value may be a blob/file or a string. The file can optionally be provided with filename.

fileToFormValue :: MonadJSM m => File -> m (FormValue File) Source #

Converts a File (e.g., the output of a FileInput) into a FormValue. The filename will be included if it is available.