@dword-design/base-config-web-extension 4.0.0 → 4.0.1
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.js +16 -5
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -7,6 +7,7 @@ import packageName from "depcheck-package-name";
|
|
|
7
7
|
import endent from "endent";
|
|
8
8
|
import fs from "fs-extra";
|
|
9
9
|
import { stringify as stringifyIni } from "ini";
|
|
10
|
+
import outputFiles from "output-files";
|
|
10
11
|
import dev from "./dev.js";
|
|
11
12
|
import lint from "./lint.js";
|
|
12
13
|
import prepublishOnly from "./prepublish-only.js";
|
|
@@ -80,11 +81,21 @@ export default defineBaseConfig(function () {
|
|
|
80
81
|
}, {
|
|
81
82
|
run: "git archive --output=dist/firefox-sources.zip HEAD"
|
|
82
83
|
}],
|
|
83
|
-
prepare: () => Promise.all([fs.ensureDir(pathLib.join(this.cwd, "userdata")),
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
84
|
+
prepare: () => Promise.all([fs.ensureDir(pathLib.join(this.cwd, "userdata")), outputFiles(this.cwd, {
|
|
85
|
+
".wxtrc": stringifyIni({
|
|
86
|
+
modules: [packageName`@wxt-dev/module-vue`],
|
|
87
|
+
outDir: "dist",
|
|
88
|
+
outDirTemplate: "{{browser}}"
|
|
89
|
+
}),
|
|
90
|
+
"web-ext.config.ts": endent`
|
|
91
|
+
import { defineWebExtConfig } from 'wxt';
|
|
92
|
+
|
|
93
|
+
export default defineWebExtConfig({
|
|
94
|
+
keepProfileChanges: true,
|
|
95
|
+
chromiumProfile: 'userdata', // chromiumArgs: ['--user-data-dir=userdata'] doesn't keep sessions across dev restarts
|
|
96
|
+
});\n
|
|
97
|
+
`
|
|
98
|
+
})]),
|
|
88
99
|
readmeInstallString: endent`
|
|
89
100
|
## Recommended setup
|
|
90
101
|
* Node.js 20.11.1
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dword-design/base-config-web-extension",
|
|
3
|
-
"version": "4.0.
|
|
3
|
+
"version": "4.0.1",
|
|
4
4
|
"repository": "dword-design/base-config-web-extension",
|
|
5
5
|
"funding": "https://github.com/sponsors/dword-design",
|
|
6
6
|
"license": "MIT",
|
|
@@ -42,6 +42,7 @@
|
|
|
42
42
|
"fs-extra": "^11.3.0",
|
|
43
43
|
"ini": "^5.0.0",
|
|
44
44
|
"lodash-es": "^4.17.21",
|
|
45
|
+
"output-files": "^3.0.0",
|
|
45
46
|
"publish-browser-extension": "^2.3.1",
|
|
46
47
|
"wxt": "npm:@dword-design/wxt-fork@^0.0.2"
|
|
47
48
|
},
|
|
@@ -53,8 +54,7 @@
|
|
|
53
54
|
"@types/ini": "^4.1.1",
|
|
54
55
|
"@types/lodash-es": "^4.17.12",
|
|
55
56
|
"express": "^5.1.0",
|
|
56
|
-
"get-port": "^7.1.0"
|
|
57
|
-
"output-files": "^3.0.0"
|
|
57
|
+
"get-port": "^7.1.0"
|
|
58
58
|
},
|
|
59
59
|
"peerDependencies": {
|
|
60
60
|
"depcheck": "*"
|