Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
“子进程”应该是一个内置的节点库。但是,当我在节点外壳中键入“require('child-process')”时,我收到错误:“找不到模块'child-process'”。任何想法为什么会发生这种情况?
使用require('child_process');(带下划线,而不是连字符)。
require('child_process');