question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Form Validation] Error when calling "validate form" with API attached

See original GitHub issue

If a form is manually validated with “validate form” an error is thrown for the call to event.stopImmediatePropagation() if there is an API attached to the form.

The fix is a simple change on form.js:942

if($module.data('moduleApi') !== undefined) {

to:

if(event && $module.data('moduleApi') !== undefined) {

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
pbarneycommented, Apr 11, 2020

Thanks @dwightbcoder . We adopted your fix in Fomantic-UI by fomantic/Fomantic-UI#709

With the number of time SUI’s maintainers have refused to even acknowledge this problem, I think you just convinced me to final port over to Fomantic. Thanks!

1reaction
lubber-decommented, Oct 6, 2022

Thanks @dwightbcoder . We adopted your fix in Fomantic-UI by https://github.com/fomantic/Fomantic-UI/pull/709

Read more comments on GitHub >

github_iconTop Results From Across the Web

Validate a form field asynchronously (after HTTP request) in ...
Manually attach an error to the form if creating the new account failed. NOT GOOD. Now you have validation in two places: BEFORE...
Read more >
Client-side form validation - Learn web development | MDN
Client-side form validation sometimes requires JavaScript if you want to customize styling and error messages, but it always requires you to think carefully ......
Read more >
React Form validation and Linking with API (Backend)
If you're just getting started with React forms and building user interfaces, Forms are very important in every application from login and ...
Read more >
Form Validation with JavaScript
This tutorial will show you how to create a JavaScript-enabled form that checks whether a user has filled in the form correctly before...
Read more >
Form and field validation - Django documentation
The validate() method on a Field handles field-specific validation that is not suitable for a validator. It takes a value that has been...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found