","dateCreated":"2019-06-13T20:15:56.000Z","upvoteCount":3,"url":"/question/thread/9a763fe9-83bd-4d3f-8df9-ec9972eb5eb7","author":{"@type":"Person","name":"Prasad Patil","image":"https://cdn.ednsquare.com/s/*/f89a1717-2322-4d93-87a4-aba26711217e.jpeg","url":"/@prasad"}},"suggestedAnswer":[]}}

How to add external JS scripts to VueJS Components?

Answer • 1 Asked • Jun 13 2019
I've to use two external scripts for the payment gateways. Right now both are put in the 'index.html' file. However, I don't want to load these files at the beginning itself. The payment gateway is needed only in when user open a specific component (using router-view). Is there anyway to achieve this?

Write your answer...

On a mission to build Next-Gen Community Platform for Developers