My background primarily lies in Java/Selenium, where I typically use syntax like...
By loginButton = By.xpath("//a[text(), 'Login']");
When it comes to JavaScript, what would the equivalent syntax be? Would it look something like this..
var login = element(by.xpath("//a[text(), 'Login']"));
Is this approach acceptable for an AngularJS application that sometimes lacks clear identifiers?