Cache and reuse results of node module file name resolution algorithm