Same require message is outputted twice, when a config file needs a loader (ex. hackerfile.babel.js) and v8flags are given, as follows:
$ ls
hacker.js node_modules/
hackerfile.babel.js package.json
$ node hacker --harmony
Unable to load: @babel/register { [Error: Cannot find module '@babel/register' from '/Users/sttk/hacker'] code: 'MODULE_NOT_FOUND' }
Loading: babel-register
Detected node flags: [ '--harmony' ]
Respawned to PID: 90011
Unable to load: @babel/register { [Error: Cannot find module '@babel/register' from '/Users/sttk/hacker'] code: 'MODULE_NOT_FOUND' }
Loading: babel-register
To fix this issue, this part should be moved to here. (In addition, this modification will enable to configure logs for require and requireFail events!)
Same require message is outputted twice, when a config file needs a loader (ex.
hackerfile.babel.js
) and v8flags are given, as follows:To fix this issue, this part should be moved to here. (In addition, this modification will enable to configure logs for
require
andrequireFail
events!)-- EDIT: I modified the range of moving part.