title: How to access a computed property from a method in a Single File Component with Vue.js
body: <p>I have a normal <em>single file component</em> which has both a <strong>computed property</strong> and some <strong>methods</strong>:</p>
  
  <pre><code>&lt;template&gt;...&lt;/template&gt;
  &lt;script&gt;
  ...
  export default {
      props: ['matches'],
      data: function() {...}  // No problem with these
  
      computed: {
          formattedMatches: function () {
              let formatted = [];
              this.matches.forEach(function($match, $i, $arr) {
                  formatted[$i] = $match[0];
              };
          });
          return formatted;
      }
      ...
  
      methods: {
          getData: function() {
              return this.formattedMatches();
          },
          ...
      }
  }
  &lt;script&gt;
  </code></pre>
  
  <p>When I try to access <code>this.formattedMatches()</code> <strong>from the method</strong>, I get a <code>[Vue warn]: Error in render: "TypeError: this.formattedMatches is not a function"
  </code>.</p>
  
  <p>What is the correct way to achieve what I want?
  Thanks in advance.</p>