title: How to add ScrollOut js to Nuxtjs
body: <p>I need your help to add scrollOut js in Nuxt js project. I am getting window not defined error.</p>
  
  <p>I have followed Nuxt's guidlines of adding a plugin like</p>
  
  <pre><code>if (process.client) {
    require('external_library')
  }
  </code></pre>
  
  <p>However this isn't working for me even after adding the plugin in the nuxt.config.js file</p>
  
  <pre><code>import ScrollOut from "scroll-out";
  
  export default {
    methods: {
      textAnim() {
        TweenMax.set("#logo, .hidetext, #about-text", { visibility: 'visible' })
        const tl = new TimelineMax();
          tl.from("#logo path", 1, { stroke: "white", drawSVG: "0" });
          tl.to("#s_1_", .5, { fill: "white", stroke: "none" }, "-=.3")
          tl.to("#k_1_", .5, { fill: "gray", stroke: "none"}, "-=.3")
          tl.staggerFrom(".hidetext", 1, { y: "130%", ease: Power4.easeOut }, 0.5);
          tl.from("#about-text", 0.5, { alpha: 0, y: 50, ease: Power1.easeOut }, "-=.5");
      }
    },
    mounted() {
      ScrollOut({
        targets: "h3, [data-splitting], ul li",
        threshold: .5
      });
      this.textAnim();
    },
    components: {
      Logo
    }
  };
  </code></pre>
  
  <p>Also in my package.json file I see <code>"nuxt": "^2.0.0",</code> version. I created the project using <code>create-nuxt-app</code>.</p>
  
  <p>Any help is really appreciated.</p>
  
  <p>Thanking you</p>