feat: MCP Browser v3.0 - 42 tools with stealth mode, multi-tab, PDF, cookies, storage, network logs, device emulation
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
const browser = require('../browser');
|
||||
|
||||
module.exports = async ({ selector = null }) => {
|
||||
await browser.start();
|
||||
if (selector) {
|
||||
const html = await browser.evaluateJS((sel) => document.querySelector(sel)?.outerHTML || null, selector);
|
||||
return { success: true, action: 'get_html', selector, html };
|
||||
}
|
||||
const html = await browser.content();
|
||||
return { success: true, action: 'get_html', html: html.substring(0, 50000) };
|
||||
};
|
||||
Reference in New Issue
Block a user