Wd.js is incrementally implementing the Mobile JsonWire Protocol Spec
Find elements in iOS applications using the UIAutomation Javascript API
eg:
wd.elementsByIosUIAutomation('.tableViews()[0].cells()', function(err, el){
el.elementByIosUIAutomation('.elements()["UICatalog"]', function(err, el){
el.getAttribute('name', function(err, name){
console.log(name);
});
});
});
Find elements in android applications using the UiSelector Class
eg:
wd.elementsByAndroidUIAutomator('new UiSelector().clickable(true)', function(err, els){
console.log("number of clickable elements:", els.length);
});
Find elements by whatever identifier is used by the platforms Accessibility framework.
eg:
wd.elementByAccessibilityId("Submit", function(err, el){
el.click();
});