Skip to content

Commit 1630a5b

Browse files
committed
refactor: uniform plugin file naming
1 parent 25db1ba commit 1630a5b

File tree

15 files changed

+11
-14
lines changed

15 files changed

+11
-14
lines changed

packages/@vuepress/plugin-active-header-links/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
const { path } = require('@vuepress/shared-utils')
22

33
module.exports = (options) => ({
4-
clientRootMixin: path.resolve(__dirname, 'mixin.js'),
4+
clientRootMixin: path.resolve(__dirname, 'clientRootMixin.js'),
55
define: {
66
AHL_SIDEBAR_LINK_SELECTOR: options.sidebarLinkSelector || '.sidebar-link',
77
AHL_HEADER_ANCHOR_SELECTOR: options.headerAnchorSelector || '.header-anchor'
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
const { path } = require('@vuepress/shared-utils')
22

3-
module.exports = (options, context) => ({
3+
module.exports = {
44
enhanceAppFiles: [
5-
path.resolve(__dirname, 'client.js')
5+
path.resolve(__dirname, 'enhanceAppFile.js')
66
],
77

88
globalUIComponents: 'BackToTop'
9-
})
9+
}

packages/@vuepress/plugin-blog/index.js

+1-3
Original file line numberDiff line numberDiff line change
@@ -161,8 +161,6 @@ module.exports = (options, ctx) => {
161161
]
162162
},
163163

164-
enhanceAppFiles: [
165-
path.resolve(__dirname, 'clientPlugin.js')
166-
]
164+
enhanceAppFiles: path.resolve(__dirname, 'enhanceAppFile.js')
167165
}
168166
}

packages/@vuepress/plugin-google-analytics/index.js

+1-3
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,5 @@ module.exports = (options = {}, context) => ({
88
return { GA_ID }
99
},
1010

11-
enhanceAppFiles: [
12-
path.resolve(__dirname, 'inject.js')
13-
]
11+
enhanceAppFiles: path.resolve(__dirname, 'enhanceAppFile.js')
1412
})

packages/@vuepress/plugin-medium-zoom/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@ module.exports = (options, context) => ({
44
define: {
55
SELECTOR: options.selector || '.content img'
66
},
7-
clientRootMixin: path.resolve(__dirname, 'mixin.js')
7+
clientRootMixin: path.resolve(__dirname, 'clientRootMixin.js')
88
})
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
const path = require('path')
22

33
module.exports = {
4-
enhanceAppFiles: path.resolve(__dirname, './client.js')
4+
enhanceAppFiles: path.resolve(__dirname, './enhanceAppFile.js')
55
}

packages/@vuepress/plugin-pagination/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ function getIntervallers (max, interval) {
1212

1313
module.exports = (options, ctx) => ({
1414
enhanceAppFiles: [
15-
path.resolve(__dirname, 'clientPlugin.js')
15+
path.resolve(__dirname, 'enhanceAppFile.js')
1616
],
1717

1818
ready () {

packages/@vuepress/plugin-pwa/index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ module.exports = (options, context) => ({
2828

2929
globalUIComponents: options.popupComponent || 'SWUpdatePopup',
3030

31-
enhanceAppFiles: path.resolve(__dirname, 'lib/inject.js'),
31+
enhanceAppFiles: path.resolve(__dirname, 'lib/enhanceAppFile.js'),
3232

3333
async generated () {
3434
const { serviceWorker } = options

packages/@vuepress/plugin-search/index.js

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ module.exports = (options) => ({
55
'@SearchBox':
66
path.resolve(__dirname, 'SearchBox.vue')
77
},
8+
89
define: {
910
SEARCH_MAX_SUGGESTIONS: options.searchMaxSuggestions || 5,
1011
SEARCH_PATHS: options.test || null

0 commit comments

Comments
 (0)