Creating a Module for the ContactsApp Sub-Application

Get introduced to listing sub-modules in Marionette and create a basic structure of our ContactManager app.

So far, we’ve created a separate module for our entities, and we’ve moved our Contact model and collection there.

If we think about it, the entities are general concepts that will be used throughout the ContactManager app. However, our main ContactManager app could contain several sub-applications, such as:

  • An app that manages contact information (create new contacts, edit their information, etc.)

  • An app that manages contact groups (friends, coworkers, etc.) and also manages the contacts that belong to them

  • An app that gives information about the ContactManager app (copyright info, compatibility, etc.)

We’ll create a module to contain our ContactsApp, which will, in turn, contain a ContactsApp.List sub-module to list our contacts. This List sub-module will contain our controller to manage the listing of the contacts and will also contain the required views. Our structure will then look like the following:

Get hands-on with 1200+ tech skills courses.