File tree Expand file tree Collapse file tree 3 files changed +13
-5
lines changed Expand file tree Collapse file tree 3 files changed +13
-5
lines changed Original file line number Diff line number Diff line change @@ -44,6 +44,10 @@ class ConfigManager {
44
44
this . _config = options ;
45
45
}
46
46
47
+ get cmsConfigFile ( ) {
48
+ return this . _cmsConfigFile ;
49
+ }
50
+
47
51
get config ( ) {
48
52
return this . _config ;
49
53
}
Original file line number Diff line number Diff line change @@ -119,7 +119,7 @@ export default function NetlifyCmsModule(moduleOptions) {
119
119
120
120
// Start watching config file
121
121
const patterns = [
122
- Utils . r ( NETLIFY_CONFIG_FILE_NAME ) ,
122
+ Utils . r ( configManager . cmsConfigFile . fileName ) ,
123
123
Utils . r ( EXTENSIONS_DIR )
124
124
] ;
125
125
@@ -128,10 +128,10 @@ export default function NetlifyCmsModule(moduleOptions) {
128
128
ignoreInitial : true
129
129
} ;
130
130
131
- const refreshFiles = _ . debounce (
132
- ( ) => this . nuxt . renderer . netlifyWebpackDevMiddleware . invalidate ( ) ,
133
- 200
134
- ) ;
131
+ const refreshFiles = _ . debounce ( ( ) => {
132
+ configManager . cmsConfigFile . readFile ( ) ;
133
+ this . nuxt . renderer . netlifyWebpackDevMiddleware . invalidate ( ) ;
134
+ } , 200 ) ;
135
135
136
136
// Watch for src Files
137
137
const fileWatcher = chokidar
Original file line number Diff line number Diff line change @@ -16,6 +16,10 @@ class CmsConfig {
16
16
get config ( ) {
17
17
return this . _config ;
18
18
}
19
+
20
+ get fileName ( ) {
21
+ return this . _fileName ;
22
+ }
19
23
}
20
24
21
25
export default CmsConfig ;
You can’t perform that action at this time.
0 commit comments