title: How to structure a single page app with knockout.js?
body: <p>I am mostly wondering how to organize things like modal windows, and dynamic pages like profiles. Should the viewModel only contain one profile view or contain all profiles loaded? This here just doesnt seem very "clean".</p>
  
  <pre><code>viewModel = {
    profile: ko.observableArray([
      new ProfileViewModel()
      //... any others loaded
    ])
  , createPostModal: {
      input: ko.observable()
    , submit: //do something to submit...
    }
  }
  
  &lt;div data-bind="foreach: profile"&gt;&lt;!-- profile html --&gt;&lt;/div&gt;
  &lt;div data-bind="with: createPostModal"&gt;&lt;/div&gt;
  </code></pre>
  
  <p>This way doesn't seem very consistent. Is there anybody who has built a single page app with knockout that can offer some advice? Code samples would be appreciated.</p>