added npm_connected to check for internet/npm access
Simplifying node package dependencies cheack

This modification creates an internal cache that
stores the dependencies check, both in-memory
during the session and on disk, so that dependency
checks don't require a call to the web.