devstark-com / vue-google-charts

Reactive Vue.js wrapper for Google Charts lib
446 stars 73 forks source link

Bug in legacy loader #208

Open mackonen opened 2 years ago

mackonen commented 2 years ago

Currently the loader checks for existing script on page with

// If already included in the page:
 if (window.google!== undefined) {
    return Promise.resolve(window.google.charts);
}

unfortunately this doesn't work if you have used other google scripts on the page that are using the google namespace...

this should be instead:

// If already included in the page:
 if (window.google.charts !== undefined) {
    return Promise.resolve(window.google.charts);
}
mackonen commented 2 years ago

And short term I'd be open to any ideas how to bypass that bug as we are using other google components.. have been trying to figure out how to override / bypass this issue.