textmode.export.js / TextmodeExportAPI / toString
Method: toString()
ts
toString(options?): string;Produces the selected layer's text content as a string.
Parameters
| Parameter | Type | Description |
|---|---|---|
options? | TXTExportOptions | Export options. |
Returns
string
The textual representation of the artwork.
Example
ts
const text = t.toString({ layer: t.layers.base, preserveTrailingSpaces: false });