Text
rust
pub fn text(args: impl Into<TextArgs>)The text component is used to display textual content.
Arguments
args: impl Into<TextArgs>This argument configures the style of the
textcomponent, including content, font size, color, alignment, and other properties. You can build it viaTextArgsBuilder.Note that since
Into<TextArgs>is implemented for types likestrandString, you can use the shorthandtext("Hello, World!").