Add node modules and compiled JavaScript from main (#54)

Co-authored-by: Oliver King <oking3@uncc.edu>
This commit is contained in:
github-actions[bot]
2022-06-29 15:41:55 -04:00
committed by GitHub
parent 4a983766a0
commit 52d71d28bd
6814 changed files with 2048539 additions and 2 deletions

28
node_modules/underscore/modules/invoke.js generated vendored Normal file
View File

@@ -0,0 +1,28 @@
import restArguments from './restArguments.js';
import isFunction from './isFunction.js';
import map from './map.js';
import deepGet from './_deepGet.js';
import toPath from './_toPath.js';
// Invoke a method (with arguments) on every item in a collection.
export default restArguments(function(obj, path, args) {
var contextPath, func;
if (isFunction(path)) {
func = path;
} else {
path = toPath(path);
contextPath = path.slice(0, -1);
path = path[path.length - 1];
}
return map(obj, function(context) {
var method = func;
if (!method) {
if (contextPath && contextPath.length) {
context = deepGet(context, contextPath);
}
if (context == null) return void 0;
method = context[path];
}
return method == null ? method : method.apply(context, args);
});
});