given a string and some options, this hook returns a tuple containing a string and some handy extras.
Guides
Example
const MyStringyWindup = () => {const [windup] = useWindupString("Hello world!");return <div>{windup}</div>;}
Arguments and return values
useWindup(// the text to turn into a winduptext: string,options: {// A function that fires every time a character is addedonChar?: (char: string) => void;// A function that fires when the windup endsonFinished?: () => void;// A function that returns how long to wait until adding the next character in millisecondspace?: (char: string) => number;// A boolean indicating whether the windup effect should be skipped.skipped?: boolean;}) = [// A string with all the characters added to the windup so farwindup: string,{// Calling this will finish the windup effect instantlyskip: () => void;// Calling this will restart the windup effectrewind: () => void;// Indicates whether the windup effect has finished or notisFinished: boolean;}]