Open cliqer opened 5 years ago
Dont use it as component
https://codesandbox.io/s/vue-typed-js-e8uil
<template>
<div>
<h2 ref="useTypedHere"></h2>
<button @click="clickToUseTyped()">Click to type</button>
</div>
</template>
<script>
import Typed from 'typed.js'
export default {
methods: {
clickToUseTyped() {
new Typed(this.$refs.useTypedHere, {
strings: ['Some text or variable here']
})
}
}
}
</script>
@reflexator thank you for this; it actually works using refs but it doesn't in my example.
I am trying to use typed as iView's -> Select -> :placeholder without luck.
It must have to do of how the custom Select component works within iView but I can't understand what the problem is and how to fix.
Many thanks for your help.
Works perfectly in template as a component but need to use it as variable within another component. Tried it as a constructor in mounted and computed but still no luck. Can you please help me? https://codesandbox.io/s/ckybh?fontsize=14 Many Thanks