Files
admin e6956aa001 Initial commit: TaskPool React panel
- React frontend with route-level code splitting
- Backend rebranded from Baihu to TaskPool
- DB brand migration script and local compatibility
2026-07-26 08:43:52 +08:00

33 lines
581 B
JavaScript
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/*
下面是测试实例
*/
const puppeteer = require('puppeteer-core');
(async () => {
// 连接 Browserless(注意 token
const browser = await puppeteer.connect({
browserWSEndpoint: 'ws://localhost:3000?token=your-secret-token'
});
const page = await browser.newPage();
// 访问百度
await page.goto('https://www.baidu.com', {
waitUntil: 'networkidle2',
timeout: 30000
});
// 截图
await page.screenshot({
path: 'baidu.png',
fullPage: true
});
console.log('✅ 截图完成:baidu.png');
await browser.close();
})();