Proractor incorporates both selenium and webdriver in the background.
One might view Protractor as an encapsulation of selenium, offering certain advantages when coding automated scripts for AngularJS web applications.
1) One such advantage is the provision of locator API, including:
by.model()
to locate elements by the 'ng-model` attribute
by.bind()` to find elements by the `ng-bind` attribute</li>
<li><code>by.repeater()
to identify elements by the `ng-repeater` attribute
However, these locator APIs ultimately translate to css selectors, allowing one to achieve the same goal using css selectors directly.
2) Another advantage is the automatic waiting feature specifically tailored for AngularJS apps https://i.sstatic.net/0FdzP.png
I have never personally utilized this feature, as I question its reliability under certain conditions.
Whether utilizing selenium Java, Protractor, selenium-webdriver, webdriverIO, or any other tool/framework, the challenge of crafting effective xpath or css selectors remains consistent. Therefore, Protractor does not hold a significant edge over other selenium-related tools/frameworks in this regard.
In terms of handling Drag and Drop functionality, Protractor relies on selenium webdriver like many other selenium-related tools/frameworks that offer similar APIs.
Ultimately, Selenium focuses solely on HTML within browsers, regardless of whether it is an AngularJS, PHP, Spring, Python, Ruby Web App, all of which are rendered into HTML for display in the browser. As a result, any selenium-related tool/framework can automate testing for AngularJS applications.