title: Nuxt. Trying to use apollo-graphql I get several errors that I didn't get with just vue
body: <p>I have integrated apollo-graphql in vue (without nuxt)and it worked.</p>
  
  <p>But now I am trying to start with Nuxt.
  In folder plugins I have included a js file with apollo initialization.</p>
  
  <p>Then in a vue file I import the file with: <code>import '~/plugins/apollo-client'</code> (I got the idea from here: <a href="https://github.com/esclapes/coosto-hackathon/blob/master/app/src/pages/index.vue" rel="nofollow noreferrer">Apollo, GraphQL, Vue and Nuxt shenanigans</a> )</p>
  
  <p>I am getting plenty of errors like not being able to use localStorage.
  For that I have installed a package called npm i nuxt-storage.</p>
  
  <p>But then at the split command:</p>
  
  <pre><code>const link = split(
    ({ query }) =&gt; {
      const { kind, operation } = getMainDefinition(query)
      return kind === 'OperationDefinition' &amp;&amp; operation === 'subscription'
    }, 
    wsLink,
    httpLink,
  )
  </code></pre>
  
  <p>I get this error: <code>Cannot read property 'request' of null</code></p>
  
  <p>I am afraid that I am going to be getting more errors after this one is solved.</p>
  
  <p>What am I doing wrong?</p>
  
  <p>Where should I place the code that I had in main.js?</p>
  
  <p>Thanks.</p>