deepLinkWithHref method
Implementation
Link? deepLinkWithHref(String href) {
for (Link l in this) {
if (l.href.toLowerCase() == href.toLowerCase() ||
l.href.toLowerCase() == '/' + href.toLowerCase()) {
return l;
} else {
Link? alternate = l.alternates.deepLinkWithHref(href);
if (alternate != null) {
return alternate;
}
Link? child = l.children.deepLinkWithHref(href);
if (child != null) {
return child;
}
}
}
return null;
}