fix: restore dynamic import for CloakBrowser
This commit is contained in:
+1
-1
@@ -1,4 +1,3 @@
|
||||
const { launch } = require('cloakbrowser');
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
|
||||
@@ -45,6 +44,7 @@ const headlessIndex = process.argv.indexOf('--headless');
|
||||
const isHeadless = headlessIndex !== -1 ? (process.argv[headlessIndex + 1] !== 'false') : false;
|
||||
|
||||
async function run() {
|
||||
const { launch } = await import('cloakbrowser');
|
||||
console.log(`Launching CloakBrowser (headless: ${isHeadless})...`);
|
||||
const browser = await launch({
|
||||
headless: isHeadless,
|
||||
|
||||
Reference in New Issue
Block a user