Page Menu
Home
Sealhub
Search
Configure Global Search
Log In
Files
F21589416
get-field-value-string.ts
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
Unknown
Size
496 B
Referenced Files
None
Subscribers
None
get-field-value-string.ts
View Options
/**
* Helper function to extract string value from a field value.
* Since TextValue extends String and all FieldValue types implement toString(),
* we can simply use toString() for all values.
*
* @param value - The value from item.get() which might be a FieldValue object or a primitive
* @returns The string representation of the value
*/
export
function
getFieldValueString
(
value
:
any
)
:
string
{
if
(
value
===
null
||
value
===
undefined
)
{
return
""
;
}
return
value
.
toString
();
}
File Metadata
Details
Attached
Mime Type
application/javascript
Expires
Sat, Nov 7, 17:35 (4 h, 1 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1182044
Default Alt Text
get-field-value-string.ts (496 B)
Attached To
Mode
rS Sealious
Attached
Detach File
Event Timeline