Typewriter usage with Frameworks
The Typewriter component works well with any framework which supports reactivity.
When using frameworks you will not need to subscribe to changes and observe the Typewriter manually. This allows you to use the Typewriter more declaratively. Using the Typewriter declaratively results in easier to understand code.
It is recommended that you use the Typewriter Composer for complex animations.
If you just want to cycle between sentences use a variant of typewriterFromSentences.
When using React you should use the @uiloos/react library. It contains the useTypewriter hook. The useTypewriter hook takes an instance of a Typewriter, and it will subscribe to changes of that Typewriter.
Alternatively use the useTypewriterFromSentences hook when your animation cycles through sentences.
In Vue you should use the @uiloos/vue library. It contains a composable called useTypewriter. The useTypewriter hook takes an instance of a Typewriter, and it will subscribe to changes of that Typewriter.
Alternatively use the useTypewriterFromSentences composable when your animation cycles through sentences.
If you are using Angular there is no need to include an extra library. As long as you use Typewriter inside of a @Component it will pick up on changes automatically.
Alternatively use the createTypewriterFromSentencesStore store creator when your animation cycles through sentences.
With Alpine you should use the @uiloos/alpine package. It contains various functions to help make typewriter animations, which you use depends on the use case.
Alternatively if you really want to create Typewriter's from HTML you can use typewriter which you can register with Alpine.data. This allows you to instantiate a Typewriter from within HTML.
Lastly use the typewriterFromSentences when your animation cycles through sentences. This allows you to create Typewriter's from within your HTML.