string

Converts a value to a string.

Target type

Signature

1string(obj::any)

Converts a value to a string.

string constructs or identifies a LaiRu value type. string works with text values. Normalize input at boundaries, escape at output boundaries, and keep encoding calls close to the place where the encoded text is needed.

Parameters

obj
Required value of type any. Supply obj positionally unless the signature shows a keyword form.

Examples

Basic call

1string(42)
The example shows the receiver and result shape. In templates, apply escaping at the final output boundary.