Implements webpage.javaScriptAlertSent()