简体   繁体   中英

when gitbook init there are error Error loading version latest

When I follow this instructions , step by step

  • mac OS 10.13
  • nodejs v8.7.0
  • npm 5.5.1
  • CLI version: 2.3.1
  • GitBook version: 3.2.3

Finally get this "gitbook init" error:

Error loading version latest: Error: Cannot find module 'extend'
at Function.Module._resolveFilename (module.js:527:15)
at Function.Module._load (module.js:476:23)
at Module.require (module.js:568:17)
at require (internal/module.js:11:18)
at Object. (/Users/jinlei/.gitbook/versions/3.2.3/lib/index.js:1:76)
at Module._compile (module.js:624:30)
at Object.Module._extensions..js (module.js:635:10)
at Module.load (module.js:545:32)
at tryModuleLoad (module.js:508:12)
at Function.Module._load (module.js:500:3)

TypeError: Cannot read property 'commands' of null

Screenshot of the error

How to solve this issue?

尝试使用对我有用的node和npm的LTS版本(分别为6.11.4和3.10.10)。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM