MCPcopy
hub / github.com/jsfiddle/togetherjs / require

Function require

togetherjs/tests/doctestjs/doctest.js:2375–2376  ·  view source on GitHub ↗
(file,cwd)

Source from the content-addressed store, hash-verified

2373exports = {};
2374
2375/* INSERT jshint.js */
2376var JSHINT;(function(){var require=function(file,cwd){var resolved=require.resolve(file,cwd||"/");var mod=require.modules[resolved];if(!mod)throw new Error("Failed to resolve module "+file+", tried "+resolved);
2377var cached=require.cache[resolved];var res=cached?cached.exports:mod();return res};require.paths=[];require.modules={};require.cache={};require.extensions=[".js",".coffee",".json"];require._core={assert:true,events:true,fs:true,path:true,vm:true};
2378require.resolve=function(){return function(x,cwd){if(!cwd)cwd="/";if(require._core[x])return x;var path=require.modules.path();cwd=path.resolve("/",cwd);var y=cwd||"/";if(x.match(/^(?:\.\.?\/|\/)/)){var m=loadAsFileSync(path.resolve(y,x))||loadAsDirectorySync(path.resolve(y,x));
2379if(m)return m}var n=loadNodeModulesSync(x,y);if(n)return n;throw new Error("Cannot find module '"+x+"'");function loadAsFileSync(x){x=path.normalize(x);if(require.modules[x]){return x}for(var i=0;i<require.extensions.length;i++){var ext=require.extensions[i];

Callers 15

devserver.jsFile · 0.85
Gruntfile.jsFile · 0.85
highlightFunction · 0.85
processFirstHelloFunction · 0.85
session.jsFile · 0.85
ui.jsFile · 0.85
refreshInviteFunction · 0.85
inviteFunction · 0.85
startup.jsFile · 0.85
templates.jsFile · 0.85
chat.jsFile · 0.85
peers.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected