title: SCSS Import Relative to Root
body: <p>I'm in the process refactoring an Angular application and as I'm moving components around to new directory locations, I'm finding that dealing <code>@import</code> paths in the components' SCSS files is getting a bit tedious. </p>
  
  <p>For example, let's say I have the file <code>src/_mixins.scss</code> in the root of my application and the component <code>src/app/my-widget/my-widget.component.scss</code> imports the SCSS like so <code>@import '../../mixins';</code>. All well and good.</p>
  
  <p>But then I decide that <code>my-widget.component</code> is really be a "shared component" under another component <code>my-thingy.component</code>, so I create a <code>shared</code> folder under <code>src/app/my-thingy</code> and move everything that was in <code>src/app/my-widget</code> into it.</p>
  
  <p>I <em>hope</em> you're still with me... So, now I've got <code>src/app/my-thingy/shared/my-widget</code> and I modify my SCSS file to import <code>@import '../../../../mixins'</code>. </p>
  
  <p><strong>Note:</strong> This is a simplified example. Some of the paths get relatively deep (no pun intended... <em>or was it?</em>) and all of these <code>.</code> and <code>/</code> are a bit much.</p>
  
  <p><strong>TL;DR</strong></p>
  
  <p>It would be <em>super-handy</em> if from the start I could have just imported  <code>_mixins.scss</code> relative to the root in all of my components' SCSS files so I don't have to keep messing with the <code>@import</code> paths when refactoring. (e.g. Something along the lines of <code>@import '~/mixins'</code>). <strong>Does something like this exist?</strong></p>
  
  <p>What I've tried (and, sadly, has failed):</p>
  
  <ol>
  <li><code>@import '~/mixins'; /** I had real hope for this one **/</code></li>
  <li><code>@import 'mixins'; /** Just being overly optimistic here **/</code></li>
  <li><code>@import '~//mixins'; /** Now I'm just making stuff up **/</code></li>
  </ol>
  
  <p><em>I understand that I'm already going to have to modify my mod files to point to the new path of the component with all of this "moving stuff around", but...  hey, one less thing, right?</em></p>