Function: getUrlInfo()
getUrlInfo(
text
,opts
):Promise
<undefined
|WAUrlInfo
>
Defined in: src/Utils/link-preview.ts:37
Given a piece of text, checks for any URL present, generates link preview for the same and returns it Return undefined if the fetch failed or no URL was found
Parameters
text
string
first matched URL in text
opts
URLGenerationOptions
= ...
Returns
Promise
<undefined
| WAUrlInfo
>
the URL info required to generate link preview