fix require path construction so that modules work from with node_modules