title: How to reset all components in Vue.js
body: <p>I'm trying to restart my component when the route changes:</p>
  
  <pre><code>  beforeRouteUpdate (to, from, next) {
      Object.assign(this.$data, this.$options.data())
        console.log(to.query);
        next();
      } 
  </code></pre>
  
  <p>but it doesn't work; it only prints the console.log. I've also tried <code>this.$options.data.call(this)</code> and <code>apply</code>.</p>