I am using nvm and via it I have set node v8.11.3 as my default. I installed the varint package globally using npm install -g --verbose varint
, specifically to see where it is being installed. Post install on running npm list -g
I can see it, but requiring it in the node repl fails. I am not sure as to what the issue is here. I am also not in a directory which has a package.json from before.
UPDATE:
which npm
: ~/.nvm/versions/node/v8.11.3/bin/npm
which node
: ~/.nvm/versions/node/v8.11.3/bin/node