[Vuejs]-How to load load google's api.js file in to my vue project

1👍

I used vue-gapi and it solved the problem.

👤Brutus

2👍

Try this:

this.gapi = window.gapi

When you load gapi as a script you need to access it through window

Also don’t load the script async, do it like this:

<script src="https://apis.google.com/js/api.js"></script>

Leave a comment