From the node.js documentation:
Modules are cached after the first time they are loaded. This means (among other things) that every call to require(\'
I am not 100% certain of what you mean by 'invalidate', but you can add the following above the require statements to clear the cache:
require
Object.keys(require.cache).forEach(function(key) { delete require.cache[key] })
Taken from @Dancrumb's comment here