Skip to content

Commit

Permalink
fix: countup.js onCompleteCallback not work
Browse files Browse the repository at this point in the history
  • Loading branch information
jizai1125 committed Jan 12, 2024
1 parent c3c7f1c commit 4aaeafa
Show file tree
Hide file tree
Showing 4 changed files with 285 additions and 4,129 deletions.
9 changes: 6 additions & 3 deletions examples/App.vue
Expand Up @@ -7,14 +7,17 @@ const startValueRef = ref(0)
const endValueRef = ref(2022.22)
const options: CountUpOptions = {
separator: '❤️'
separator: '❤️',
onCompleteCallback() {
console.log('onCompleteCallback finished !!!')
}
}
let countUp: ICountUp | undefined
const onInit = (ctx: ICountUp) => {
countUp = ctx
}
const onFinished = () => {
console.log('finished')
console.log('finished!!!')
}
const countupRef = ref<InstanceType<typeof CountUp>>()
Expand Down Expand Up @@ -50,7 +53,7 @@ const changeEndVal = () => {
:decimal-places="2"
:options="options"
:loop="2"
:delay="5"
:delay="2"
@init="onInit"
@finished="onFinished">
<template #prefix>
Expand Down

0 comments on commit 4aaeafa

Please sign in to comment.