This is a very hot path in larger apps. A typical app might have 1-2 path mappings, and ~8 extensions defined. This means that for a given path lookup:
It'll need to enumerate n many paths to look up, in the example above it would be 16
For those 16 paths, potentially call 16 existsSync for every single file
This is a very hot path in larger apps. A typical app might have 1-2 path mappings, and ~8 extensions defined. This means that for a given path lookup:
n
many paths to look up, in the example above it would be 16