title: How to trigger an Apollo query in a Vue component event?
body: <p>How to trigger an Apollo GraphQL query on a <code>mounted</code> event in a Vue.js component. </p>
  
  <p>Here is what my code looks like: </p>
  
  <pre><code>&lt;template&gt;
  &lt;/template&gt;
  
  &lt;script&gt;
  import gql from 'graphql-tag';
  
  const myQuery = gql`
    query someQuery {
      books{
        id
     }
  }`
  
  export default {
    data: () =&gt; ({
      books: []
    }),
    apollo: {
      books: {
        query: myQuery,
      },
    },
    mounted () {
    // run the appollo query here as well ?
    }
  };
  &lt;/script&gt;
  </code></pre>
  
  <p>The query runs fine on the first load of the component, but how can I get it to run with various events?</p>