Brian Cardarella recently open sourced Ember EasyForm, an Ember.js library to make working with forms less tedious.

By wielding the library you can turn a form like this:

<form>
  <div class="input string">
    <label>First name</label>
    {{view Ember.TextField valueBinding='firstName' name='first_name' viewName='firstNameField'}}
  </div>
  <div class="input string">
    <label>Last name</label>
    {{view Ember.TextField valueBinding='firstName' name='last_name' viewName='lastNameField'}}
  </div>
  <div class="input string">
    <label>Age</label>
    {{view Ember.TextField valueBinding='age' name='age' viewName='ageField'}}
  </div>

</form>

Into this:

{{#formFor controller}}
  {{input firstName}}
  {{input lastName}}
  {{input age}}
  {{submit}}
{{/formFor}}

Brian’s intro post says it is a work-in-progress and encourages people to submit their feature ideas as GitHub issues. The library uses semantic versioning and hasn’t hit 1.0 yet, but it shows a lot of promise.

If you’re using Ember now is a great time to get involved!


Have comments? Send a tweet to @TheChangelog on Twitter.

Subscribe to The Changelog Weekly – our weekly email covering everything that hits our open source radar.