Skip to content

Commit f799b87

Browse files
committed
Refactored duplicate templates down a bit
1 parent 5915fa6 commit f799b87

File tree

8 files changed

+7
-63
lines changed

8 files changed

+7
-63
lines changed

generator/index.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ module.exports = (api, _options) => {
6767
if (options.components.background) {
6868
api.render(
6969
{
70-
[`./src/background.${fileExt}`]: `./template/background/src/background.${fileExt}`
70+
[`./src/background.${fileExt}`]: `./template/background/src/background.js`
7171
},
7272
{ name, ...options }
7373
)
@@ -76,7 +76,7 @@ module.exports = (api, _options) => {
7676
if (options.components.contentScripts) {
7777
api.render(
7878
{
79-
[`./src/content-scripts/content-script.${fileExt}`]: `./template/content-scripts/src/content-scripts/content-script.${fileExt}`
79+
[`./src/content-scripts/content-script.${fileExt}`]: `./template/content-scripts/src/content-scripts/content-script.js`
8080
},
8181
{ name, ...options }
8282
)
@@ -86,7 +86,7 @@ module.exports = (api, _options) => {
8686
api.render(
8787
{
8888
'./src/popup/App.vue': `./template/popup/src/popup/App.${fileExt}.vue`,
89-
[`./src/popup/main.${fileExt}`]: `./template/popup/src/popup/main.${fileExt}`
89+
[`./src/popup/main.${fileExt}`]: `./template/popup/src/popup/main.js`
9090
},
9191
{ name, ...options }
9292
)
@@ -102,7 +102,7 @@ module.exports = (api, _options) => {
102102
api.render(
103103
{
104104
'./src/options/App.vue': `./template/options/src/options/App.${fileExt}.vue`,
105-
[`./src/options/main.${fileExt}`]: `./template/options/src/options/main.${fileExt}`
105+
[`./src/options/main.${fileExt}`]: `./template/options/src/options/main.js`
106106
},
107107
{ name, ...options }
108108
)
@@ -118,7 +118,7 @@ module.exports = (api, _options) => {
118118
api.render(
119119
{
120120
'./src/override/App.vue': `./template/override/src/override/App.${fileExt}.vue`,
121-
[`./src/override/main.${fileExt}`]: `./template/override/src/override/main.${fileExt}`
121+
[`./src/override/main.${fileExt}`]: `./template/override/src/override/main.js`
122122
},
123123
{ name, ...options }
124124
)
@@ -134,7 +134,7 @@ module.exports = (api, _options) => {
134134
api.render(
135135
{
136136
'./src/standalone/App.vue': `./template/standalone/src/standalone/App.${fileExt}.vue`,
137-
[`./src/standalone/main.${fileExt}`]: `./template/standalone/src/standalone/main.${fileExt}`
137+
[`./src/standalone/main.${fileExt}`]: `./template/standalone/src/standalone/main.js`
138138
},
139139
{ name, ...options }
140140
)
@@ -151,7 +151,7 @@ module.exports = (api, _options) => {
151151
api.render(
152152
{
153153
'./src/devtools/App.vue': `./template/devtools/src/devtools/App.${fileExt}.vue`,
154-
[`./src/devtools/main.${fileExt}`]: `./template/devtools/src/devtools/main.${fileExt}`
154+
[`./src/devtools/main.${fileExt}`]: `./template/devtools/src/devtools/main.js`
155155
},
156156
{ name, ...options }
157157
)

generator/template/background/src/background.ts

Lines changed: 0 additions & 13 deletions
This file was deleted.

generator/template/content-scripts/src/content-scripts/content-script.ts

Lines changed: 0 additions & 1 deletion
This file was deleted.

generator/template/devtools/src/devtools/main.ts

Lines changed: 0 additions & 10 deletions
This file was deleted.

generator/template/options/src/options/main.ts

Lines changed: 0 additions & 8 deletions
This file was deleted.

generator/template/override/src/override/main.ts

Lines changed: 0 additions & 8 deletions
This file was deleted.

generator/template/popup/src/popup/main.ts

Lines changed: 0 additions & 8 deletions
This file was deleted.

generator/template/standalone/src/standalone/main.ts

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)