Skip to content

Commit f15e9de

Browse files
authored
Docs: Fix "Async Completion" code example [ci skip] (#2428)
1 parent 25c1a28 commit f15e9de

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/getting-started/4-async-completion.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ When not using any of the previous options, you can define your task as an [`asy
127127
const fs = require('fs');
128128

129129
async function asyncAwaitTask() {
130-
const { version } = fs.readFileSync('package.json');
130+
const { version } = JSON.parse(fs.readFileSync('package.json', 'utf8'));
131131
console.log(version);
132132
await Promise.resolve('some result');
133133
}

0 commit comments

Comments
 (0)