From 11cf196e3eb2a361f755b80bb81ee5dd8eecd331 Mon Sep 17 00:00:00 2001 From: Bert De Block Date: Wed, 7 Feb 2024 16:22:46 +0100 Subject: [PATCH] chore: remove automatic exclusion of msw's worker file --- index.js | 16 ---------------- package.json | 4 +--- .../dummy/public}/mockServiceWorker.js | 0 yarn.lock | 2 +- 4 files changed, 2 insertions(+), 20 deletions(-) rename {public => tests/dummy/public}/mockServiceWorker.js (100%) diff --git a/index.js b/index.js index 03704ab..89622ac 100644 --- a/index.js +++ b/index.js @@ -8,20 +8,4 @@ module.exports = { enableTypeScriptTransform: true, }, }, - - treeForPublic(tree) { - const host = this._findHost(); - const shouldExcludePublicFiles = host.env === 'production'; - - if (shouldExcludePublicFiles) { - return; - } - - const funnel = require('broccoli-funnel'); - const mergeTrees = require('broccoli-merge-trees'); - - return mergeTrees([tree, funnel(host.trees.public)], { - overwrite: true, - }); - }, }; diff --git a/package.json b/package.json index 7bdf654..88c172b 100644 --- a/package.json +++ b/package.json @@ -53,8 +53,6 @@ }, "dependencies": { "@babel/core": "^7.23.3", - "broccoli-funnel": "^3.0.5", - "broccoli-merge-trees": "^4.2.0", "ember-auto-import": "^2.7.0", "ember-cli-babel": "^8.2.0", "lodash.merge": "^4.6.2" @@ -133,7 +131,7 @@ "configPath": "tests/dummy/config" }, "msw": { - "workerDirectory": "public" + "workerDirectory": "tests/dummy/public" }, "release-it": { "plugins": { diff --git a/public/mockServiceWorker.js b/tests/dummy/public/mockServiceWorker.js similarity index 100% rename from public/mockServiceWorker.js rename to tests/dummy/public/mockServiceWorker.js diff --git a/yarn.lock b/yarn.lock index d5f24ae..95a631e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3571,7 +3571,7 @@ broccoli-funnel@^2.0.0, broccoli-funnel@^2.0.2: symlink-or-copy "^1.0.0" walk-sync "^0.3.1" -broccoli-funnel@^3.0.5, broccoli-funnel@^3.0.8: +broccoli-funnel@^3.0.8: version "3.0.8" resolved "https://registry.yarnpkg.com/broccoli-funnel/-/broccoli-funnel-3.0.8.tgz#f5b62e2763c3918026a15a3c833edc889971279b" integrity sha512-ng4eIhPYiXqMw6SyGoxPHR3YAwEd2lr9FgBI1CyTbspl4txZovOsmzFkMkGAlu88xyvYXJqHiM2crfLa65T1BQ==