Skip to content

Commit

Permalink
fix($core): vuepress dev broken on nodejs v10 and greater (close: #…
Browse files Browse the repository at this point in the history
…1063) (close: #1064)

Refs:

- nodejs/node#21203
- nodejs/node@cbc3ef6
  • Loading branch information
ulivz committed Dec 3, 2018
1 parent 6870051 commit adef3a1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/@vuepress/core/lib/dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,8 @@ module.exports = async function dev (sourceDir, cliOptions = {}) {
const { host, displayHost } = await resolveHost(cliOptions.host || ctx.siteConfig.host)

// debug in a running dev process.
process.stdout.on('data', chunk => {
process.stdin &&
process.stdin.on('data', chunk => {
const parsed = chunk.toString('utf-8').trim()
if (parsed === '*') {
console.log(Object.keys(ctx))
Expand Down

0 comments on commit adef3a1

Please sign in to comment.