title: WebStorm has marked all files in a directory as non-project files
body: <p>WebStorm has marked all files in a subdirectory of my project (the server portion of the root) as <strong>non-project files</strong>. </p>
  
  <p>It happened sometime during my conversion to Babel and then again to TypeScript. I've removed the TypeScript stuff, wondering if it's something to do with that configuration. I believe it's just a WebStorm setting somewhere - because my tests run, builds work, all that. </p>
  
  <p>Whenever I refactor or rename a file it says:</p>
  
  <blockquote>
    <p>"Selected element is used from non-project files. These usages won't be renamed. Proceed anyway?"</p>
  </blockquote>
  
  <p>It also highlights the code in these files differently.</p>
  
  <p>Each of these file's icons has a small <code>x</code> in the top corner.</p>
  
  <p><a href="https://www.jetbrains.com/help/idea/non-project-files-access-dialog.html" rel="nofollow noreferrer">In their docs</a> it says that these are " non-project files (e.g, library sources, external sources etc." This makes me think at some point I just marked a whole folder external at some point, thought I don't know where that could be.</p>
  
  <p><strong>Update</strong> I've tried deleting <code>.idea</code> folder and then running <em>invalidate cache and restart</em>. This didn't fix it either.</p>
  
  <p>The <code>myProject.iml</code> file looks like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;module type="WEB_MODULE" version="4"&gt;
    &lt;component name="NewModuleRootManager"&gt;
      &lt;content url="file://$MODULE_DIR$"&gt;
        &lt;excludeFolder url="file://$MODULE_DIR$/.tmp" /&gt;
        &lt;excludeFolder url="file://$MODULE_DIR$/temp" /&gt;
        &lt;excludeFolder url="file://$MODULE_DIR$/tmp" /&gt;
      &lt;/content&gt;
      &lt;orderEntry type="inheritedJdk" /&gt;
      &lt;orderEntry type="sourceFolder" forTests="false" /&gt;
    &lt;/component&gt;
  &lt;/module&gt;
  </code></pre>