Invalidate source-map-support cache when require.cache
is cleaned and file is re-required
#1503
Labels
you can do this
Good candidate for a pull request.
Invalidate source-map-support cache when
require.cache
is cleaned and file is re-required.Fixes #268
Is
emptyCacheBetweenOperations
sufficient? Or will this cause unnecessary fs calls within source-map-support?If we want to avoid a cache invalidation API in source-map-support, should we implement our own fs caching? It will call us because of empty cache every time, but we can implement caching and fs reads on our side.
Related to cspotcode/node-source-map-support#32
Maybe can use WeakMap to associate require.cache entry w/cached sourcemap. So that when require.cache is cleared, we automatically re-populate our own cache?
The text was updated successfully, but these errors were encountered: