title: How to get ngtemplate-loader working with Webpack 3, Angular 1, TypeScript and ES 6 modules?
body: <p>I am trying configure ngtemplate-loader to be able to use my angular template in a TypeScript file like so:</p>
  
  <pre><code>import myTemplateUrl from './hello-angular2-template.thtml';
  angular
      .module('pd')
      .component('helloAngular2', {
          templateUrl: myTemplateUrl,
      });
  </code></pre>
  
  <p>Loader definition in webpack.config:</p>
  
  <pre><code>module: {
      rules: [
          // Angular Template HTML
          {
              test: /\.thtml$/,
              use: [
                  {
                      loader: 'ngtemplate-loader',
                  },
                  {
                      loader: 'html-loader',
                  }
              ],
          },
  </code></pre>
  
  <p>(The strange *.ththml suffix is just so, that no standard html-loader can interfere.)</p>
  
  <p>However the template never gets loaded (is undefined after import).</p>
  
  <p>I tried to add </p>
  
  <pre><code>options: {
      exportAsEs6Default: true
  }
  </code></pre>
  
  <p>to the chained html-loader, but that did not work out, too.</p>
  
  <p><strong>Full example project</strong>: <a href="https://github.com/eekboom/ng-webpack" rel="nofollow noreferrer">https://github.com/eekboom/ng-webpack</a></p>