How to use Google Analytics?

    Otherwise, to use Google Analytics with your Nuxt.js application, we recommend you create a file :

    Then, we tell Nuxt.js to import it in our main application:

    1. export default {
    2. { src: '~plugins/ga.js', mode: 'client' }
    3. }

    Voilà, Google Analytics is integrated into your Nuxt.js application and will track every page view!