dynamic_links library
Dynamic Links values shared by flutterflow_cloud and its emulator
(specs/34): FFXDynamicLink, FFXLinkCampaign, and the short-code,
location and define rules of the link host.
Classes
- FFXDynamicLink
- A resolved link: what an app needs to navigate and attribute, nothing about who made it.
- FFXLinkCampaign
- Campaign attribution on a link: the five UTM dimensions, set when the link is made and never changed.
Constants
- ffxLinkAdminPathPrefix → const String
-
The links Worker's private admin surface,
/__edge/*on the environment's bare family host;LINK_ADMIN_PATH_PREFIX. No link uses it, and an app never routes a URL under it. - ffxLinkDomainDefine → const String
-
The build define carrying the project's link host
(
my-app-a1b2c3-link-dev.flutterflow.cloud);LINK_DOMAIN_DEFINE. - ffxLinkSchemeDefine → const String
-
The build define carrying the app's custom URL scheme;
LINK_SCHEME_DEFINE. - ffxShortCodeAlphabet → const String
- The characters a short code is drawn from (base62).
Functions
-
isLinkAdminPath(
String path) → bool -
Whether
pathis under ffxLinkAdminPathPrefix, read leniently so a disguised form is caught too: any case, percent-encoded, without its leading slash, with doubled slashes or backslashes, or the bare/__edge;isLinkAdminPath. -
isReservedShortCode(
String code) → bool -
Whether
codenames one of the link host's own routes and is never a link. -
isShortCode(
String code) → bool -
Whether
codecould be a link's short code: base62, at most 64 characters, not reserved. -
isUtmKey(
String key) → bool -
Whether
keyis a UTM key, which a link's route parameters never carry. -
linkLocation(
String routePath, Map< String, String> parameters) → String -
A router location:
routePath, thenparametersas a query with its keys sorted, so one link always yields one location. -
locationOfAppSchemeUri(
Uri uri, String scheme) → String? -
The location an "Open in app" URL names:
<scheme>:///product?id=42is/product?id=42;<scheme>:////,<scheme>:///and<scheme>://are/. Null for any other URL, including one on another scheme or with a host. -
shortCodeOfPath(
String path) → String? -
The short code a link URL's
pathnames, or null when the path is not exactly one code segment.