has method

Future<bool> has(
  1. AbstractSelector selector
)

Implementation

Future<bool> has(AbstractSelector selector) async {
  try {
    var selected = await (await page).$(selector.selector);
    return selected != null;
  } catch (e) {
    return false;
  }
}