GithubHelp home page GithubHelp logo

Comments (7)

ericelliott avatar ericelliott commented on June 4, 2024

Thanks for the suggestion. It's certainly a good one. In the mean time, you can override the markValid and markInvalid functions, but be aware, I'm planning to change the function signatures in the next version.

from h5validate.

jan-harmsen avatar jan-harmsen commented on June 4, 2024

+1 regarding errorClass for different element.
I am currently evaluating various html5 form libs and just stumbled on h5Validate which looks quite good on first impression.
What does concern me is your remark about changing the API (function signatures) in the next version, since this breaks backwards compatibility. What is the general strategy towards providing backwards compatibility in future versions of h5Validate? Thanks!

from h5validate.

ericelliott avatar ericelliott commented on June 4, 2024

I think what I'll do is offer callbacks that you can pass in for markValid and markInvalid so that you can do whatever you need to do to customize your implementation, and still take advantage of all the testing and best practices that we've baked into h5Validate.

FYI, the function signatures have already been updated - replaced the parameters with an options collection so that we can make non-breaking changes if we need to modify options in the future.

I don't anticipate any more breaking changes. The roadmap for 1.0 is to let users pass in their custom callbacks during initialization, so that won't require any incompatible changes to the API.

from h5validate.

jan-harmsen avatar jan-harmsen commented on June 4, 2024

THANKS for responding that fast and with such good news, sounds great, that's exactly what I had hoped for :-)

from h5validate.

ericelliott avatar ericelliott commented on June 4, 2024

In case you're curious -- those callbacks have been pushed as of 0.6.0 -- but I haven't written any documentation for them. You can pass in callbacks for both markValid and markInvalid methods, and there's some other new hotness as well: $('#myField').h5Validate('isValid') will return true or false, as will $('myForm').h5Validate('allValid); -- but there is a chance that I'll change the function signatures on those before the 1.0 release.

from h5validate.

tmikaeld avatar tmikaeld commented on June 4, 2024

Please let us know if you change those, as i'm currently using them extensively.

from h5validate.

ericelliott avatar ericelliott commented on June 4, 2024

isValid changed today. You might want to look at the diff from the last pull.

from h5validate.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.