@intuned/runtime-dev 1.6.0-dev-52-8 → 1.6.0-dev-52-9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -48,9 +48,11 @@ async function getProductionPlaywrightConstructs({
48
48
  const isChrome127There = await (0, _fsExtra.exists)(chromium127Path);
49
49
  const userAgent = `Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/${isChrome127There ? 127 : 125}.0.0.0 Safari/537.36`;
50
50
  const userDataDir = await createUserDirWithPreferences();
51
- const context = await playwright.chromium.launchPersistentContext("", {
51
+ const context = await playwright.chromium.launchPersistentContext(userDataDir, {
52
52
  headless,
53
- viewport: null
53
+ viewport: null,
54
+ proxy,
55
+ downloadsPath
54
56
  });
55
57
  context.once("close", async () => {
56
58
  try {
@@ -77,6 +79,7 @@ async function getProductionPlaywrightConstructs({
77
79
  let page = context.pages().at(0);
78
80
  if (page) {
79
81
  const scriptString = await (0, _fsExtra.readFile)(assetsFile, "utf8");
82
+ await page.evaluate(scriptString);
80
83
  } else {
81
84
  page = await context.newPage();
82
85
  }
@@ -106,6 +109,7 @@ async function getPlaywrightConstructsForMode(mode, cdpAddress, authSession) {
106
109
  if (pages.length > 0) {
107
110
  page = pages[0];
108
111
  const scriptString = await fs.readFile(assetsFile, "utf8");
112
+ await page.evaluate(scriptString);
109
113
  } else {
110
114
  page = await context.newPage();
111
115
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intuned/runtime-dev",
3
- "version": "1.6.0-dev-52-8",
3
+ "version": "1.6.0-dev-52-9",
4
4
  "description": "Intuned runtime",
5
5
  "exports": {
6
6
  ".": "./dist/index.js",