1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 | 'use strict';
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 | function reactProdInvariant(code) {
|
21 | var argCount = arguments.length - 1;
|
22 |
|
23 | var message = 'Minified React error #' + code + '; visit ' + 'http://facebook.github.io/react/docs/error-decoder.html?invariant=' + code;
|
24 |
|
25 | for (var argIdx = 0; argIdx < argCount; argIdx++) {
|
26 | message += '&args[]=' + encodeURIComponent(arguments[argIdx + 1]);
|
27 | }
|
28 |
|
29 | message += ' for the full message or use the non-minified dev environment' + ' for full errors and additional helpful warnings.';
|
30 |
|
31 | var error = new Error(message);
|
32 | error.name = 'Invariant Violation';
|
33 | error.framesToPop = 1;
|
34 |
|
35 | throw error;
|
36 | }
|
37 |
|
38 | module.exports = reactProdInvariant; |
\ | No newline at end of file |