Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

anyone already implement script2ify on a laravel vue project? #33

Open
lolchaps opened this issue Dec 11, 2018 · 1 comment
Open

anyone already implement script2ify on a laravel vue project? #33

lolchaps opened this issue Dec 11, 2018 · 1 comment

Comments

@lolchaps
Copy link

lolchaps commented Dec 11, 2018

I am trying to implement script2ify on my laravel vue project, anyone already implement script2ify function on a laravel vue project? where should I put the script2ify function? Any help greatly appreciated,

@lolchaps lolchaps changed the title How to use script2ify on a laravel vue project? anyone already implement script2ify on a laravel vue project? Dec 11, 2018
@lolchaps lolchaps reopened this Dec 11, 2018
@TheFrankman
Copy link

@lolchaps It's the same as you would do anything.
Follow the normal install instructions i.e. yarn add vue-script2

Then in you vue template add

<script>
import VS2 from 'vue-script2'
Vue.use(VS2)
export default {
  mounted() {
    VS2.load('https://the-libary.js').then(() => {
      //init whatever
    });
  }
}

However, I'm i'm yet to figure out how to get it into the footer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants