import { Meta, Source } from '@storybook/addon-docs/blocks'

<Meta title='@dxtmisha/en/functional-basic/Functions/toString - Conversion of a value to a string'/>

# `toString`

A utility for converting a value to a string. Returns an empty string if the value is null or undefined.

**Parameters:**
- `value: string | null | undefined` — The value for conversion.

**Returns:**
`string` — The string representation of the value.


## Examples

<Source
  language='typescript'
  code={`
import { toString } from '@dxtmisha/functional-basic'

toString('Hello')         // 'Hello'
toString(null)            // ''
toString(undefined)       // ''

  `}
/>
