Home > @dinofe/xt-core > isUrlLike
# isUrlLike() function
校验字符串是否是 URL 链接
Signature:
export declare function isUrlLike(url: string): boolean;
# Parameters
| Parameter | Type | Description | 
|---|---|---|
| url | string | 任意字符串 | 
Returns:
boolean
是否是 URL 链接
# Remarks
是否以 http:// 或 https:// 开头
# Example
import { isUrlLike } from '@dinofe/xt-core/common'
isUrlLike('https://www.foo.bar') // true
