Skip to content

Commit

Permalink
doc: fix typo in ESM example
Browse files Browse the repository at this point in the history
Refs: #37468

PR-URL: #40275
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Derek Lewis <DerekNonGeneric@inf.is>
Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Zijian Liu <lxxyxzj@gmail.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
tniessen authored and nodejs-github-bot committed Oct 4, 2021
1 parent 2a3a9b8 commit 4bd8e0e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/api/esm.md
Expand Up @@ -979,7 +979,7 @@ async function getPackageType(url) {
// Compose a file path to a package.json in the same directory,
// which may or may not exist
const packagePath = resolvePath(dir, 'package.json');
// Try to read the possibly non-existant package.json
// Try to read the possibly nonexistent package.json
const type = await readFile(packagePath, { encoding: 'utf8' })
.then((filestring) => JSON.parse(filestring).type)
.catch((err) => {
Expand Down

0 comments on commit 4bd8e0e

Please sign in to comment.