Introducing form-for. ReactJS Forms Made Easy – Pedro Silva Moreira – Medium

Introducing form-for. #ReactJS Forms Made Easy

  • Binding componentsAs you can see on the code above, each field has a type set to it; some even have a couple extra properties.Now, we need to tell form-for what components to render.
  • I created a package for bootstrap components that makes your life veeery easy.
  • Building the formNow, let’s put together the User, the bootstrap components and the Form and Field tags.4.
  • The code is very straight forward, just like the one you saw above.And if you want more sandbox examples, I have two others in my profile: MobXFormFor goes really well with MobX.
  • If you don’t like comment too, lemme know how you think it could be

I’ve been coding for a few years and played with a few technologies. In this path, I’ve become a big fan of a Rails gem called simple_form. I’m also a fan of React. With these two in mind, I decided…

2. Binding componentsAs you can see on the code above, each field has a type set to it; some even have a couple extra properties.Now, we need to tell form-for what components to render. I created a package for bootstrap components that makes your life veeery easy. It also aims to promote accessibility.3. Building the formNow, let’s put together the User, the bootstrap components and the Form and Field tags.4. LiveI created an extended version of the form we created. In this one the user has a list of todoItems as well, which adds a new degree of fun. The code is very straight forward, just like the one you saw above.And if you want more sandbox examples, I have two others in my profile: MobXFormFor goes really well with MobX. I highly recommend giving it a try: RepoCheck out the repo, there a lot more instructions in there. If you like it, share with your friends and colleagues . I’m looking forward to hear your thoughts the comments below or GitHub PR/Issue.If you don’t like comment too, lemme know how you think it could be

Introducing form-for. ReactJS Forms Made Easy – Pedro Silva Moreira – Medium