title: How load all local resource in a specific directory?
body: <p>I'm developing by Openui5 a portal. My portal have 2 apps. I I have organized the code in folders:</p>
  
  <pre><code>root
    |
    |____app1
    |____app2
  </code></pre>
  
  <p>For example, in app1 directory I have some sub directory (misc, fragment, master, detail) and in detail folder I have a subfolder detail--->form.</p>
  
  <p>To work, my project needs:</p>
  
  <pre><code>sap.ui.localResources("app1.misc");
  sap.ui.localResources("app1.fragment");
  sap.ui.localResources("app1.master");
  sap.ui.localResources("app1.detail");
  sap.ui.localResources("app1.detail.form");
  </code></pre>
  
  <p>I want write a function <code>getPaths(dir)</code> </p>
  
  <pre><code>var aPaths= getPaths("app1");
  for( var i = 0; i &lt; aPaths.length; i++) {
        var path=aPaths[i];
        sap.ui.localResources(path);
  } 
  </code></pre>
  
  <p>How can I implement the function?</p>