title: In Vue.JS method on passed string trim() doesn't work
body: <p>So I am trying to remove white space from one of the returned object's property with .trim() function but it doesn't work.</p>
  
  <p>I already tried applying JS functions such as .replace(/\s/g,'') but it is also not working</p>
  
  <pre><code>&lt;script&gt;
  export default {
      name: 'navigation',
      props: ["navigation"],
      methods:{
          whiteSpace: function(a){
              var str = a;
              str.toLowerCase();
              str.trim();
              console.log(str);
  
  
              return str;
          }
      }
  }
  &lt;/script&gt;
  </code></pre>
  
  <p>HTML</p>
  
  <pre><code>&lt;li&gt;
    &lt;router-link :to="{ path: whiteSpace(nav.linkTitle) }"&gt;
         {{nav.linkTitle}}
    &lt;/router-link&gt;
  &lt;/li&gt;
  </code></pre>
  
  <p>It should return string without white space but it doesn't remove white space.</p>