eoka 0.14.1

Stealth browser automation for Rust. Puppeteer/Playwright alternative with anti-bot bypass.
Documentation
1
2
3
4
5
6
7
function(query) {
    if (query.kind === 'css') return Array.from(document.querySelectorAll(query.selector));
    if (query.kind === 'placeholder') return Array.from(document.querySelectorAll('[placeholder]')).filter(el => el.getAttribute('placeholder') === query.text);
    if (query.kind === 'role') return Array.from(document.querySelectorAll('[role]')).filter(el => el.getAttribute('role') === query.role);
    if (query.kind !== 'text') throw new Error('Unsupported locator');
    return (TEXT_CANDIDATES)(query.text, query.exact ? 'exact' : 'contains', false);
}