We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents eb6322b + 7cb89d1 commit 35ad83aCopy full SHA for 35ad83a
dist/unobtrusive-bootstrap.js
@@ -20,9 +20,19 @@
20
$.validator.unobtrusive.options = {
21
errorClass: defaultOptions.errorClass,
22
validClass: defaultOptions.validClass,
23
+ errorElement: 'div',
24
+ errorPlacement: function (error, element) {
25
+ error.addClass('invalid-feedback');
26
+
27
+ if ($element.next().is(".input-group-append")) {
28
+ $error.insertAfter($element.next());
29
+ } else {
30
+ $error.insertAfter($element);
31
+ }
32
33
};
34
}
35
else {
36
console.warn('$.validator is not defined. Please load this library **after** loading jquery.validate.js and jquery.validate.unobtrusive.js');
37
-})(jQuery);
38
+})(jQuery);
0 commit comments