Skip to content

Instantly share code, notes, and snippets.

@kof
Last active August 29, 2015 14:01
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save kof/5031516857d16ced14b2 to your computer and use it in GitHub Desktop.
Save kof/5031516857d16ced14b2 to your computer and use it in GitHub Desktop.
Project structure

app

  1. lib (app unspecific, installed from bower, npm or component) - lib1
  2. src (app specific) - screens (take components and build screens)
    • screen1
      • models
        • Model1.js
      • views
        • View1.js
      • collections
        • Collection1.js
      • templates
      • Controller.js (handles routes, exposes screens public api) - components (building blocks for screens, they don't talk to each other)
    • component1 (without standard structure, but preferably mvc)
      • index.js
    • component2
      • modules
      • views
      • collections
      • templates - app.js exports global app context, init the app - main.js run any global stuff before app.js, then app.js - requireConfig.js

node_modules

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment