From 2153bfa41efa7bdc35bc1d14e161fb294ee15a98 Mon Sep 17 00:00:00 2001 From: Daniel Hobi Date: Thu, 18 Jul 2024 11:22:03 +0200 Subject: [PATCH 1/2] Document customElements option --- entries/validate.xml | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/entries/validate.xml b/entries/validate.xml index 640ed6c..e6e5cba 100644 --- a/entries/validate.xml +++ b/entries/validate.xml @@ -538,6 +538,19 @@ + + + By default, only the following elements are validatable input, select, textarea, [contenteditable] + Register additional elements. Main use case is for validating web components. +

Example: Register <my-custom-element> to be validatable as well.

+

+					$("#myform").validate({
+						customElements: ["my-custom-element"]
+					});
+					
+
+ +
From 9530dfdcfbd52cbf21fdf7059cc65bdf43d49049 Mon Sep 17 00:00:00 2001 From: Daniel Hobi Date: Thu, 18 Jul 2024 16:27:01 +0200 Subject: [PATCH 2/2] Update wording --- entries/validate.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/entries/validate.xml b/entries/validate.xml index e6e5cba..abff4dc 100644 --- a/entries/validate.xml +++ b/entries/validate.xml @@ -540,8 +540,8 @@ - By default, only the following elements are validatable input, select, textarea, [contenteditable] - Register additional elements. Main use case is for validating web components. + By default, only the following elements are validatable: input, select, textarea and [contenteditable] + Use this to register your additional/custom elements, for example web components.

Example: Register <my-custom-element> to be validatable as well.


 					$("#myform").validate({