Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
Download
81155 views
1
/**
2
* Copyright 2013-2014, Facebook, Inc.
3
* All rights reserved.
4
*
5
* This source code is licensed under the BSD-style license found in the
6
* LICENSE file in the root directory of this source tree. An additional grant
7
* of patent rights can be found in the PATENTS file in the same directory.
8
*
9
* @providesModule ReactErrorUtils
10
* @typechecks
11
*/
12
13
"use strict";
14
15
var ReactErrorUtils = {
16
/**
17
* Creates a guarded version of a function. This is supposed to make debugging
18
* of event handlers easier. To aid debugging with the browser's debugger,
19
* this currently simply returns the original function.
20
*
21
* @param {function} func Function to be executed
22
* @param {string} name The name of the guard
23
* @return {function}
24
*/
25
guard: function(func, name) {
26
return func;
27
}
28
};
29
30
module.exports = ReactErrorUtils;
31
32