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:
export default {
{ src: '~plugins/ga.js', mode: 'client' }
}
Voilà, Google Analytics is integrated into your Nuxt.js application and will track every page view!