package brr

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type

Form elements and form data.

Element

type t

The type for HTMLFormElement objects.

val of_el : Brr.El.t -> t

of_el e is a form from element e. This throws a JavaScript error if e is not a form element.

val to_el : t -> Brr.El.t

to_el f is f as an an element.

val name : t -> Jstr.t

name f is the name of f.

val method' : t -> Jstr.t

method' f is the method of f.

val target : t -> Jstr.t

target f is the target of f.

val action : t -> Jstr.t

action f is the action of f.

val enctype : t -> Jstr.t

enctype f is the enctype of f.

val accept_charset : t -> Jstr.t

accept_charset f is the charset accepted by f.

val autocomplete : t -> Jstr.t

autocomplete f refelects the value of the autocomplete attribute of f.

val no_validate : t -> bool

no_validate f refelects the value of the novalidate attribute of f.

val check_validity : t -> bool

check_validity f is true if the form's children controls all satisfy their validation constraints.

val report_validity : t -> bool

report_validity f is like check_validity but also reports problems to the user.

val request_submit : t -> Brr.El.t option -> unit

request_submist f el requests the form to be submited using button el or the form itself if unspecified.

val reset : t -> unit

reset f resets the form.

val submit : t -> unit

submit f submits the form.

Data

module Data : sig ... end

Form data.

Events

module Ev : sig ... end

Form events

OCaml

Innovation. Community. Security.