Skip to content

Commit

Permalink
fix($dev): using config.yml/toml doesn't reload changes (close: #520)
Browse files Browse the repository at this point in the history
  • Loading branch information
ulivz committed May 29, 2018
1 parent c228de9 commit 6048eb9
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions lib/dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,13 @@ module.exports = async function dev (sourceDir, cliOptions = {}) {

// watch config file
const configWatcher = chokidar.watch([
path.join(sourceDir, '.vuepress/config.js')
], { ignoreInitial: true })
'.vuepress/config.js',
'.vuepress/config.yml',
'.vuepress/config.toml'
], {
cwd: sourceDir,
ignoreInitial: true
})
configWatcher.on('change', update)

// also listen for frontmatter changes from markdown files
Expand Down

0 comments on commit 6048eb9

Please sign in to comment.