title: How to load javascript es6 module determined at runtime?
body: <p>I am developing a SPA which contains multiple dashboards. Each dashboard is a set of Web Components respecting a layout. These components are not known statically. They are determined at run-time.</p>
  
  <p>What I want to achieve is the following scenario:</p>
  
  <ol>
  <li>Application starts.</li>
  <li>The application performs XHR to fetch dashboards representations from a REST service.</li>
  <li>User sees dashboards listed by name.</li>
  <li>User clicks on a dashboard item. (say dashboard 1)</li>
  <li>The application determines the necessary components needed to load dashboard 1 (web components)</li>
  <li>Load <strong>web components</strong> and their <strong>dependencies</strong>.</li>
  </ol>
  
  <p>I am pretty aware of loading web components dynamically which was answered <a href="https://stackoverflow.com/a/21649225/6174341">here</a></p>
  
  <p>My actual problem is</p>
  
  <blockquote>
    <p>how to load a web component with their dependencies at run-time
    without having to load duplicate dependencies?</p>
    
    <p>Are there any module formats or practices to follow when packaging the
    web components?</p>
  </blockquote>