The value to convert.
The type to convert the value to, expressed as a SpecTypeName.
The converted value, or undefined if the conversion failed.
Note: We can convert most values to strings, and strings to most other types. Apart from that, we return undefined as we don’t want to make any assumptions.
Generated using TypeDoc
Tries to convert a value to a given type.