O'Reilly logo

Advanced Express Web Application Development by Andrew Keig

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Feature: List repositories

Let's build the client for our feature List repositories. Each item in the list consists of a repository name, a short description, and a checkbox; which allows us to add or remove the repository from the project.

What follows is an HTML template ./templates/repositories.hbs for a repository item:

<li>
  <label class="checkbox inline">
  <input id="{{id}}" type="checkbox" {{enabled}} value="{{name}}"><h4 class="media-heading repoItem">{{name}}</h4>
  <small>{{description}}</small>
  </label>
</li>

Let's add a Repository model. We add a function Repository that extends the Backbone Model type and add a hash of default values for the four properties in our model. The enabled property signifies that a repository is included in the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required