/
configuration.js
62 lines (45 loc) · 1.54 KB
/
configuration.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
const configuration = {
// Log level
logLevel: 'error',
// Allows using SFC without changes
pureSFC: true,
// keep render method unpatched, moving sideEffect to componentDidUpdate
pureRender: true,
// Allows SFC to be used, enables "intermediate" components used by Relay, should be disabled for Preact
allowSFC: true,
// Allow hot reload of effect hooks
reloadHooks: true,
// Disable "hot-replacement-render"
disableHotRenderer: false,
// Disable "hot-replacement-render" when injection into react-dom is made
disableHotRendererWhenInjected: true,
// Controls `react-🔥-dom patch` notification
showReactDomPatchNotification: true,
// Hook on babel component register.
onComponentRegister: false,
// Hook on React renders for a first time component
onComponentCreate: false,
// flag to completely disable RHL for SFC. Probably don't use it without dom patch made.
ignoreSFC: false,
// ignoreSFC when injection into react-dom is made
ignoreSFCWhenInjected: true,
// flag to completely disable RHL for Components
ignoreComponents: false,
// default value for AppContainer errorOverlay
errorReporter: undefined,
// Global error overlay
ErrorOverlay: undefined,
};
export const internalConfiguration = {
// control proxy creation
disableProxyCreation: false,
};
export const setConfiguration = config => {
// not using Object.assing for IE11 compliance
for (const i in config) {
if (config.hasOwnProperty(i)) {
configuration[i] = config[i];
}
}
};
export default configuration;