MCPcopy Create free account
hub / github.com/danielstocks/react-sortable / invariant

Function invariant

bundle.js:351–370  ·  view source on GitHub ↗
(condition, format, a, b, c, d, e, f)

Source from the content-addressed store, hash-verified

349}
350
351function invariant(condition, format, a, b, c, d, e, f) {
352 validateFormat(format);
353
354 if (!condition) {
355 var error;
356 if (format === undefined) {
357 error = new Error('Minified exception occurred; use the non-minified dev environment ' + 'for the full error message and additional helpful warnings.');
358 } else {
359 var args = [a, b, c, d, e, f];
360 var argIndex = 0;
361 error = new Error(format.replace(/%s/g, function () {
362 return args[argIndex++];
363 }));
364 error.name = 'Invariant Violation';
365 }
366
367 error.framesToPop = 1; // we don't care about invariant's own frame
368 throw error;
369 }
370}
371
372module.exports = invariant;
373/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(0)))

Callers 15

checkPropTypesFunction · 0.70
bundle.jsFile · 0.70
traverseAllChildrenImplFunction · 0.70
onlyChildFunction · 0.70
recomputePluginOrderingFunction · 0.70
publishEventForPluginFunction · 0.70
publishRegistrationNameFunction · 0.70
precacheChildNodesFunction · 0.70
getNodeFromInstanceFunction · 0.70
assertIsMountedFunction · 0.70
executeDirectDispatchFunction · 0.70

Calls 1

validateFormatFunction · 0.70

Tested by

no test coverage detected