我正在尝试require()并在phatomJS中使用此logging module(它也有一些依赖项),但它失败并打印出此错误:
C:\node\scrap>phantomjs app.js
ReferenceError: Can't find variable: process
phantomjs://platform/index.js:3
ReferenceError: Can't find variable: process
phantomjs://platform/index.js:9
TypeError: undefined is not an object (evaluating 'chalk.bold.red')
phantomjs://platform/index.js:29
TypeError: undefined is not a constructor (evaluating 'log.info('All settings loaded, start with exe
cution')')
phantomjs://code/app.js:16 in global code
我不知道为什么或出了什么问题?我错过了什么?