JavaScriptExecutor : Part-1
JavaScriptExecutor Before we discuss on JavaScriptExecutor, We will discuss what is JavaScript actually? So, What is JavaScript ? Java Script is an object-oriented programming language commonly used to create interactive effects within the web browser to Handle WebElements within Web Page. It is used by Selenium WebDriver to do handle WebElements. Now lets us discuss, What is JavaScriptExecutor? The JavaScriptExecutor is an interface that provides mechanisms to execute javascript through the Selenium Driver. To run JavaScript in the context of the currently selected frame or window, it provides two methods i.e. "executescript" and "executeAsyncScript" The basic advantage of JavaScriptExecutor is that Selenium provides a way to run Java Script in webdriver. Sometimes the locator can not work, in that case the JavaScriptExecutor will help interact with web elements on a particular webpage. The reason behind this is, even Selenium webdriver convert the bindings ...