Skip to content

Latest commit

 

History

History
21 lines (14 loc) · 1.37 KB

README.md

File metadata and controls

21 lines (14 loc) · 1.37 KB

vite-dynamic-form

A modularized and strongly-typed form implementation which is backwards-compatible with old data, running local migrations to ensure data integrity.

Edit on StackBlitz ⚡️

Important Files

Form Components:

  • Example Component -- simple component that clearly demonstrates basic form behavior
  • Parent Component -- more compplicated component that shows how to nest form components inside one another
  • Slot Component -- the most advanced component that dynamically hosts different children

Important Mentions

  • We determine global form state such as "Should the submit button be enabled" by defining a special key _type and recursively searching for errors in the form state tree. There are probably better ways to do this but premature optimization is the root of all evil