test/jsonpipe.js
// A require to work on node or browser
A require to work on node or browser
A require to work on node or browser
function smartRequire(name, windowName) {
    var stripName = function(moduleName) {
        if (!moduleName) {
            return moduleName;
        }
        var strippedName = moduleName.match(/\/([^\/]+)$/);
        return strippedName ? strippedName[1] : moduleName;
    };
    if (typeof require === 'function') {
        return require(name);
    }
    return window[windowName || stripName(name)];
}
function smartRequire ( name , windowName ) { var stripName = function ( moduleName ) { if ( ! moduleName ) { return moduleName ; } var strippedName = moduleName . match ( / \/([^\/]+)$ / ) ; return strippedName ? strippedName [ 1 ] : moduleName ; } ; if ( typeof require === 'function' ) { return require ( name ) ; } return window [ windowName || stripName ( name ) ] ; }
A require to work on node or browser
A require to work on node or browser