getBaseElementHrefFromDom function

String? getBaseElementHrefFromDom()

Returns the href attribute of the base element if it is present.

Based on getBaseElementHrefFromDom

Implementation

String? getBaseElementHrefFromDom() {
  return document.querySelector('base')?.getAttribute('href');
}