wxt 0.6.5 → 0.6.6

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.
package/dist/index.cjs CHANGED
@@ -1393,7 +1393,8 @@ async function getInternalConfig(inlineConfig, command) {
1393
1393
  cwd: root,
1394
1394
  globalRc: true,
1395
1395
  rcFile: ".webextrc",
1396
- overrides: mergedConfig.runner
1396
+ overrides: inlineConfig.runner,
1397
+ defaults: userConfig.runner
1397
1398
  });
1398
1399
  const finalConfig = {
1399
1400
  browser,
@@ -1635,7 +1636,7 @@ function findEffectedSteps(changedFile, currentOutput) {
1635
1636
  // src/index.ts
1636
1637
  var import_async_mutex = require("async-mutex");
1637
1638
  var import_consola3 = require("consola");
1638
- var import_node_path13 = require("path");
1639
+ var import_node_path14 = require("path");
1639
1640
 
1640
1641
  // src/core/build/buildEntrypoints.ts
1641
1642
  var vite3 = __toESM(require("vite"), 1);
@@ -4257,13 +4258,37 @@ function createSafariRunner() {
4257
4258
  };
4258
4259
  }
4259
4260
 
4261
+ // src/core/runners/manual.ts
4262
+ var import_node_path12 = require("path");
4263
+ function createManualRunner() {
4264
+ return {
4265
+ async openBrowser(config) {
4266
+ config.logger.info(
4267
+ `Load "${(0, import_node_path12.relative)(
4268
+ process.cwd(),
4269
+ config.outDir
4270
+ )}" as an unpacked extension manually`
4271
+ );
4272
+ },
4273
+ async closeBrowser() {
4274
+ }
4275
+ };
4276
+ }
4277
+
4278
+ // src/core/utils/wsl.ts
4279
+ async function isWsl() {
4280
+ const { default: isWsl2 } = await import("is-wsl");
4281
+ return isWsl2;
4282
+ }
4283
+
4260
4284
  // src/core/runners/index.ts
4261
4285
  async function createExtensionRunner(config) {
4262
4286
  if (config.browser === "safari")
4263
4287
  return createSafariRunner();
4264
- const { default: isWsl } = await import("is-wsl");
4265
- if (isWsl)
4288
+ if (await isWsl())
4266
4289
  return createWslRunner();
4290
+ if (config.runnerConfig.config?.disabled)
4291
+ return createManualRunner();
4267
4292
  return createWebExtRunner();
4268
4293
  }
4269
4294
 
@@ -4353,7 +4378,7 @@ function reloadHtmlPages(groups, server, config) {
4353
4378
  }
4354
4379
 
4355
4380
  // src/core/clean.ts
4356
- var import_node_path12 = __toESM(require("path"), 1);
4381
+ var import_node_path13 = __toESM(require("path"), 1);
4357
4382
  var import_fast_glob4 = __toESM(require("fast-glob"), 1);
4358
4383
  var import_fs_extra15 = __toESM(require("fs-extra"), 1);
4359
4384
  var import_consola2 = require("consola");
@@ -4368,7 +4393,7 @@ async function clean(root = process.cwd()) {
4368
4393
  ];
4369
4394
  import_consola2.consola.debug("Looking for:", tempDirs.map(import_picocolors4.default.cyan).join(", "));
4370
4395
  const directories = await (0, import_fast_glob4.default)(tempDirs, {
4371
- cwd: import_node_path12.default.resolve(root),
4396
+ cwd: import_node_path13.default.resolve(root),
4372
4397
  absolute: true,
4373
4398
  onlyDirectories: true,
4374
4399
  deep: 2
@@ -4379,16 +4404,16 @@ async function clean(root = process.cwd()) {
4379
4404
  }
4380
4405
  import_consola2.consola.debug(
4381
4406
  "Found:",
4382
- directories.map((dir) => import_picocolors4.default.cyan(import_node_path12.default.relative(root, dir))).join(", ")
4407
+ directories.map((dir) => import_picocolors4.default.cyan(import_node_path13.default.relative(root, dir))).join(", ")
4383
4408
  );
4384
4409
  for (const directory of directories) {
4385
4410
  await import_fs_extra15.default.rm(directory, { force: true, recursive: true });
4386
- import_consola2.consola.debug("Deleted " + import_picocolors4.default.cyan(import_node_path12.default.relative(root, directory)));
4411
+ import_consola2.consola.debug("Deleted " + import_picocolors4.default.cyan(import_node_path13.default.relative(root, directory)));
4387
4412
  }
4388
4413
  }
4389
4414
 
4390
4415
  // package.json
4391
- var version2 = "0.6.5";
4416
+ var version2 = "0.6.6";
4392
4417
 
4393
4418
  // src/core/utils/defineConfig.ts
4394
4419
  function defineConfig(config) {
@@ -4436,11 +4461,11 @@ async function createServer2(config) {
4436
4461
  if (changes.type === "no-change")
4437
4462
  return;
4438
4463
  internalConfig.logger.info(
4439
- `Changed: ${Array.from(new Set(fileChanges.map((change) => change[1]))).map((file) => import_picocolors5.default.dim((0, import_node_path13.relative)(internalConfig.root, file))).join(", ")}`
4464
+ `Changed: ${Array.from(new Set(fileChanges.map((change) => change[1]))).map((file) => import_picocolors5.default.dim((0, import_node_path14.relative)(internalConfig.root, file))).join(", ")}`
4440
4465
  );
4441
4466
  const rebuiltNames = changes.rebuildGroups.flat().map((entry) => {
4442
4467
  return import_picocolors5.default.cyan(
4443
- (0, import_node_path13.relative)(internalConfig.outDir, getEntrypointOutputFile(entry, ""))
4468
+ (0, import_node_path14.relative)(internalConfig.outDir, getEntrypointOutputFile(entry, ""))
4444
4469
  );
4445
4470
  }).join(import_picocolors5.default.dim(", "));
4446
4471
  internalConfig = await getLatestInternalConfig();