How to select a single item in protractor

You can get an indexed element from an array returned with

// Get the 5th element matching the .dfdf css selector
element.all(by.css('.dfdf')).get(4).sendKeys('foo');

Leave a Comment