validate
(
)
:
Promise
const
fv
=
FormValidation
.
formValidation
(
document
.
getElementById
(
'demoForm'
)
,
{
...
}
)
;
// Validate the form when click on a link or normal button
fv
.
validate
(
)
.
then
(
function
(
status
)
{
// status can be one of the following value
// 'NotValidated': The form is not yet validated
// 'Valid': The form is valid
// 'Invalid': The form is invalid
...
}
)
;
import
formValidation
from
'formvalidation/dist/es6/core/Core'
;
const
fv
=
formValidation
(
document
.
getElementById
(
'demoForm'
)
,
{
...
}
)
;
// Validate the form when click on a link or normal button
fv
.
validate
(
)
.
then
(
function
(
status
)
{
// status can be one of the following value
// 'NotValidated': The form is not yet validated
// 'Valid': The form is valid
// 'Invalid': The form is invalid
...
}
)
;