title: Object.assign is not a function
body: <p>I'm using babel with gulp and create a simple DOM library in ES6. But after running and when i'm going to use it, I got the <code>Object.assign is not a function</code> in chrome console. </p>
  
  <p>this is the gulp code</p>
  
  <pre><code>gulp.task('scripts', function() {
      return gulp.src(src + 'js/*.js')
        .pipe(babel())
        .pipe(concat('main.js'))
        .pipe(gulp.dest(dest + 'js'));
  });
  </code></pre>
  
  <p>this is the class file</p>
  
  <pre><code>class DOM {
      constructor( selector ) {
          var elements = document.querySelectorAll(selector);
  
          this.length = elements.length;
  
          Object.assign(this, elements);
      }
  
      ...
  
  }
  
  const dom = selector =&gt; new DOM(selector);
  </code></pre>
  
  <p>and I'm using it in client side like <code>dom('#elId');</code></p>