Skip to content

A diagram #3

Open
Open
@mohsen1

Description

@mohsen1

screen shot 2015-03-02 at 1 11 43 pm

In this diagram I made a case for how we can structure the core library.

  • Template fragments are little pieces of Handlebar HTML files that are specifically named and have required fields. We can have fragments for fields, validations and so on. Users obviously can override those templates.
  • JSON Schema is the base schema for generating the form
  • Customizer object is the object that extends JSON Schema (or maybe with a whole different syntax. Doesn't really have to follow JSON Schema structure). This object can contain custom validators and other things that JSON Schema can't have
  • Full Schema is a single object that contain everything assembler needs to assemble a form
  • Assembler is the core piece here. It's doing the templating and event bindings
  • Form HTML is obviously the final result that have two components
  • Event dispatcher that handles events inside the form and expose it as an API for the user (a user in this case can be angular directive )
  • Data I/O a set of setter/getter functions for transferring data. The data can be an instance of standard FormData

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions