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

How does data-did-init work with vue? #61

Open
aonghas opened this issue May 1, 2023 · 1 comment
Open

How does data-did-init work with vue? #61

aonghas opened this issue May 1, 2023 · 1 comment

Comments

@aonghas
Copy link

aonghas commented May 1, 2023

How do I call the data-did-init method when implementing with Vue? The function is a string so I'm not sure how I can call something within a SFC in Vue? thanks!

@rikschennink
Copy link
Collaborator

Use Tick.DOM.create to create the counter and you can pass the init as a property.

var tick = Tick.DOM.create(element, {
    value: 1000,
    didInit: function(tick) {
        console.log('hello!');
    }
});

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