What is JavaScript Executor and how it helps in Selenium Automation?
Hi Brett,
JavaScript Executor is an interface of Selenium WebDriver that has the functionality similar to that of Java Script and can interact with HTML DOM elements. Instead of using driver.findElement
method of the Selenium WebDriver we can use JavaScriptExecutor Interface to perform similar action on the Page. It provides advantages over FindElement method while handling tricky XPath as well as finding element which are sometimes hidden.