Splitting
Splitting copied to clipboard
A problem with using vue
<span data-splitting>{{ message }}</span>
message
is not changed after using data-splitting
,
The complete code is as follows: https://codepen.io/jinhang87/pen/abyPLwX
You can't use the standard Splitting method for reactive frameworks, since they regularly reset their templates to sync with reactive values.
You need to generate the HTML first and then pass it to the template as a computed value. See here: https://splitting.js.org/guide.html#splitting-html