I am using a package called
react-type-animation
for a typewriter text effect with react and tailwind css. But when I add dynamic class to the TypeAnimation component, it does not work. Here is the code that I have tried:
<TypeAnimation sequence={[
"TEXT1",
2000,
"TEXT2",
2000,
"TEXT3",
2000,
]}
speed={50}
className={`text-${theme}-500`}
wrapper="span"
repeat={Infinity}
/>
But when i use static class like text-red-500, it works fine. Is there any way to use dynamic class to the TypeAnimation component?