-
-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How it works? #18
Comments
Hi! At the moment there is very little visible, but the angular 1 adaptor is the best example. The idea is that it handles validation (at least) in the core, and form generation in adaptors (probably one adaptor set for each combination of CSS framework / JS framework). So far most of work has been on the core. |
Hey @Jamm, This library is intended to be the base used by other, more framework-specific ports. (We plan on creating an Angular 2 port first, but also a web components port, React, perhaps Angular 1, etc.) It's kind of a work in progress at the moment, but here's how things are setup at a high level:
|
We only very recently started work on this, after some debate and discussion (see here) on how to approach the problem. Our main goal was to combine efforts into 1, powerful/flexible form validation library that we could create lightweight adapters on top of rather than all create our own individual libraries. We'd love to hear your input if you'd be interested in helping! :) |
@bvaughn so because of step 3, we will need to write line of JS for each controller we have in form? |
Not exactly. The above steps are kind of a guideline for the adapters we're building. So for instance, when we create a forms-js-angular-2 adapter- that will be a really lightweight library that just connects Forms JS classes to Angular's injector and exposes a couple of directives for creating forms via markup. Steps 1-6 are kind of how these directives will hook into Forms JS for validation. For a user to use Forms JS, it will be much simpler. They'll either pass a JSON schema or a form validation schema. (More info on this discussion thread and this drive doc.) Its also fairly similar to how my current form library, formFor works: (I only mention formFor because its documentation is a little prettier and easier to read than our discussion thread.) |
I believe this question's been answered sufficiently as far as the issue-tracker goes. If you'd like to chat more about this effort, @Jamm, I'd be happy to hop on Gitter or Hangout with you and discuss. :) |
Hello!
Please give 1 small (in code) to show how it works. Is it about building forms from JS (as formly, JSX) or it's about validation (analogue of ng-messages) or something else?
The text was updated successfully, but these errors were encountered: