code: function registerExtension(ext) {
    var old = oldHandlers[ext] || oldHandlers[".js"] || require.extensions[".js"];
  
    var loader = normalLoader;
    if (process.env.running_under_istanbul) loader = istanbulLoader;
  
    require.extensions[ext] = function (m, filename) {
      if (shouldIgnore(filename)) {
        old(m, filename);
      } else {
        loader(m, filename, old);
      }
    };
  }
docs: Register a loader for an extension.