isStreamCdnHosted

fun String.isStreamCdnHosted(cdnHost: String? = null): Boolean

Returns whether this URL is served from a Stream CDN host that understands resizing query parameters.

Parameters

cdnHost

An optional custom Stream CDN host (e.g. a proxied domain). When provided, the URL host is matched against it with a substring check, mirroring iOS' StreamCDNRequester(cdnHost:); when null, the default STREAM_CDN_HOST_PATTERN is used.