react-relay 11.0.2 → 13.0.0-rc.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (177) hide show
  1. package/README.md +47 -0
  2. package/ReactRelayContainerUtils.js.flow +1 -1
  3. package/ReactRelayContext.js +1 -1
  4. package/ReactRelayContext.js.flow +3 -4
  5. package/ReactRelayFragmentContainer.js.flow +25 -25
  6. package/ReactRelayFragmentMockRenderer.js.flow +2 -2
  7. package/ReactRelayLocalQueryRenderer.js.flow +7 -8
  8. package/ReactRelayPaginationContainer.js.flow +112 -59
  9. package/ReactRelayQueryFetcher.js.flow +10 -11
  10. package/ReactRelayQueryRenderer.js.flow +116 -82
  11. package/ReactRelayQueryRendererContext.js.flow +1 -1
  12. package/ReactRelayRefetchContainer.js.flow +42 -39
  13. package/ReactRelayTestMocker.js.flow +17 -15
  14. package/ReactRelayTypes.js.flow +11 -11
  15. package/RelayContext.js.flow +4 -4
  16. package/__flowtests__/ReactRelayFragmentContainer-flowtest.js.flow +2 -3
  17. package/__flowtests__/ReactRelayPaginationContainer-flowtest.js.flow +12 -8
  18. package/__flowtests__/ReactRelayRefetchContainer-flowtest.js.flow +11 -7
  19. package/__flowtests__/RelayModern-flowtest.js.flow +79 -47
  20. package/__flowtests__/RelayModernFlowtest_badref.graphql.js.flow +6 -5
  21. package/__flowtests__/RelayModernFlowtest_notref.graphql.js.flow +6 -5
  22. package/__flowtests__/RelayModernFlowtest_user.graphql.js.flow +5 -4
  23. package/__flowtests__/RelayModernFlowtest_users.graphql.js.flow +5 -4
  24. package/__flowtests__/__generated__/ReactRelayFragmentContainerFlowtest_viewer.graphql.js.flow +72 -0
  25. package/__flowtests__/__generated__/ReactRelayFragmentContainerFlowtest_viewer2.graphql.js.flow +72 -0
  26. package/__flowtests__/__generated__/ReactRelayPaginationContainerFlowtestQuery.graphql.js.flow +227 -0
  27. package/__flowtests__/__generated__/ReactRelayPaginationContainerFlowtest_viewer.graphql.js.flow +164 -0
  28. package/__flowtests__/__generated__/ReactRelayRefetchContainerFlowtestQuery.graphql.js.flow +227 -0
  29. package/__flowtests__/__generated__/ReactRelayRefetchContainerFlowtest_viewer.graphql.js.flow +164 -0
  30. package/__flowtests__/__generated__/RelayModernFlowtest_badref.graphql.js.flow +66 -0
  31. package/__flowtests__/__generated__/RelayModernFlowtest_notref.graphql.js.flow +66 -0
  32. package/__flowtests__/__generated__/RelayModernFlowtest_user.graphql.js.flow +59 -0
  33. package/__flowtests__/__generated__/RelayModernFlowtest_users.graphql.js.flow +61 -0
  34. package/assertFragmentMap.js.flow +3 -3
  35. package/buildReactRelayContainer.js.flow +12 -11
  36. package/getRootVariablesForFragments.js.flow +3 -5
  37. package/hooks.js +1 -1
  38. package/hooks.js.flow +6 -7
  39. package/index.js +1 -1
  40. package/index.js.flow +7 -8
  41. package/isRelayEnvironment.js.flow +1 -1
  42. package/jest-react/enqueueTask.js.flow +56 -0
  43. package/jest-react/index.js.flow +12 -0
  44. package/jest-react/internalAct.js.flow +138 -0
  45. package/legacy.js +1 -1
  46. package/legacy.js.flow +1 -1
  47. package/lib/ReactRelayContainerUtils.js +1 -1
  48. package/lib/ReactRelayContext.js +1 -1
  49. package/lib/ReactRelayFragmentContainer.js +22 -16
  50. package/lib/ReactRelayFragmentMockRenderer.js +3 -3
  51. package/lib/ReactRelayLocalQueryRenderer.js +8 -9
  52. package/lib/ReactRelayPaginationContainer.js +97 -39
  53. package/lib/ReactRelayQueryFetcher.js +3 -3
  54. package/lib/ReactRelayQueryRenderer.js +87 -54
  55. package/lib/ReactRelayQueryRendererContext.js +1 -1
  56. package/lib/ReactRelayRefetchContainer.js +39 -26
  57. package/lib/ReactRelayTestMocker.js +8 -9
  58. package/lib/ReactRelayTypes.js +1 -1
  59. package/lib/RelayContext.js +4 -3
  60. package/lib/assertFragmentMap.js +3 -2
  61. package/lib/buildReactRelayContainer.js +8 -8
  62. package/lib/getRootVariablesForFragments.js +2 -3
  63. package/lib/hooks.js +6 -6
  64. package/lib/index.js +8 -8
  65. package/lib/isRelayEnvironment.js +1 -1
  66. package/lib/jest-react/enqueueTask.js +53 -0
  67. package/lib/jest-react/index.js +13 -0
  68. package/lib/jest-react/internalAct.js +115 -0
  69. package/lib/legacy.js +1 -1
  70. package/lib/multi-actor/ActorChange.js +30 -0
  71. package/lib/multi-actor/index.js +11 -0
  72. package/lib/multi-actor/useRelayActorEnvironment.js +29 -0
  73. package/lib/readContext.js +1 -1
  74. package/lib/relay-hooks/EntryPointContainer.react.js +4 -4
  75. package/lib/relay-hooks/EntryPointTypes.flow.js +1 -1
  76. package/lib/relay-hooks/FragmentResource.js +342 -89
  77. package/lib/relay-hooks/InternalLogger.js +1 -1
  78. package/lib/relay-hooks/LRUCache.js +1 -1
  79. package/lib/relay-hooks/LazyLoadEntryPointContainer_DEPRECATED.react.js +5 -5
  80. package/lib/relay-hooks/MatchContainer.js +2 -2
  81. package/lib/relay-hooks/ProfilerContext.js +1 -1
  82. package/lib/relay-hooks/QueryResource.js +172 -29
  83. package/lib/relay-hooks/RelayEnvironmentProvider.js +6 -4
  84. package/lib/relay-hooks/SuspenseResource.js +130 -0
  85. package/lib/relay-hooks/loadEntryPoint.js +1 -1
  86. package/lib/relay-hooks/loadQuery.js +42 -20
  87. package/lib/relay-hooks/preloadQuery_DEPRECATED.js +25 -16
  88. package/lib/relay-hooks/prepareEntryPoint_DEPRECATED.js +1 -1
  89. package/lib/relay-hooks/useBlockingPaginationFragment.js +5 -6
  90. package/lib/relay-hooks/useEntryPointLoader.js +3 -3
  91. package/lib/relay-hooks/useFetchTrackingRef.js +3 -2
  92. package/lib/relay-hooks/useFragment.js +7 -7
  93. package/lib/relay-hooks/useFragmentNode.js +5 -5
  94. package/lib/relay-hooks/useIsMountedRef.js +1 -1
  95. package/lib/relay-hooks/useIsOperationNodeActive.js +3 -3
  96. package/lib/relay-hooks/useIsParentQueryActive.js +1 -1
  97. package/lib/relay-hooks/useLazyLoadQuery.js +4 -4
  98. package/lib/relay-hooks/useLazyLoadQueryNode.js +11 -5
  99. package/lib/relay-hooks/useLoadMoreFunction.js +9 -13
  100. package/lib/relay-hooks/useMemoOperationDescriptor.js +3 -3
  101. package/lib/relay-hooks/useMemoVariables.js +3 -3
  102. package/lib/relay-hooks/useMutation.js +18 -7
  103. package/lib/relay-hooks/usePaginationFragment.js +3 -4
  104. package/lib/relay-hooks/usePreloadedQuery.js +6 -6
  105. package/lib/relay-hooks/useQueryLoader.js +31 -11
  106. package/lib/relay-hooks/useRefetchableFragment.js +1 -1
  107. package/lib/relay-hooks/useRefetchableFragmentNode.js +14 -18
  108. package/lib/relay-hooks/useRelayEnvironment.js +3 -3
  109. package/lib/relay-hooks/useStaticFragmentNodeWarning.js +3 -3
  110. package/lib/relay-hooks/useSubscribeToInvalidationState.js +3 -2
  111. package/lib/relay-hooks/useSubscription.js +11 -8
  112. package/multi-actor/ActorChange.js.flow +58 -0
  113. package/multi-actor/index.js.flow +14 -0
  114. package/multi-actor/useRelayActorEnvironment.js.flow +49 -0
  115. package/package.json +3 -3
  116. package/react-relay-hooks.js +2 -2
  117. package/react-relay-hooks.min.js +2 -2
  118. package/react-relay-legacy.js +2 -2
  119. package/react-relay-legacy.min.js +2 -2
  120. package/react-relay.js +2 -2
  121. package/react-relay.min.js +2 -2
  122. package/readContext.js.flow +1 -1
  123. package/relay-hooks/EntryPointContainer.react.js.flow +9 -16
  124. package/relay-hooks/EntryPointTypes.flow.js.flow +25 -26
  125. package/relay-hooks/FragmentResource.js.flow +359 -93
  126. package/relay-hooks/InternalLogger.js.flow +1 -1
  127. package/relay-hooks/LRUCache.js.flow +1 -1
  128. package/relay-hooks/LazyLoadEntryPointContainer_DEPRECATED.react.js.flow +33 -47
  129. package/relay-hooks/MatchContainer.js.flow +4 -3
  130. package/relay-hooks/ProfilerContext.js.flow +1 -1
  131. package/relay-hooks/QueryResource.js.flow +217 -26
  132. package/relay-hooks/RelayEnvironmentProvider.js.flow +15 -5
  133. package/relay-hooks/SuspenseResource.js.flow +115 -0
  134. package/relay-hooks/__flowtests__/EntryPointTypes/EntryPointElementConfig-flowtest.js.flow +5 -4
  135. package/relay-hooks/__flowtests__/EntryPointTypes/NestedEntrypoints-flowtest.js.flow +2 -2
  136. package/relay-hooks/__flowtests__/__generated__/useFragmentFlowtest_user.graphql.js.flow +59 -0
  137. package/relay-hooks/__flowtests__/__generated__/useFragmentFlowtest_users.graphql.js.flow +61 -0
  138. package/relay-hooks/__flowtests__/useBlockingPaginationFragment-flowtest.js.flow +11 -10
  139. package/relay-hooks/__flowtests__/useFragment-flowtest.js.flow +55 -32
  140. package/relay-hooks/__flowtests__/usePaginationFragment-flowtest.js.flow +11 -10
  141. package/relay-hooks/__flowtests__/useRefetchableFragment-flowtest.js.flow +11 -10
  142. package/relay-hooks/__flowtests__/utils.js.flow +21 -32
  143. package/relay-hooks/loadEntryPoint.js.flow +7 -13
  144. package/relay-hooks/loadQuery.js.flow +50 -32
  145. package/relay-hooks/preloadQuery_DEPRECATED.js.flow +31 -22
  146. package/relay-hooks/prepareEntryPoint_DEPRECATED.js.flow +7 -13
  147. package/relay-hooks/useBlockingPaginationFragment.js.flow +14 -12
  148. package/relay-hooks/useEntryPointLoader.js.flow +8 -11
  149. package/relay-hooks/useFetchTrackingRef.js.flow +3 -3
  150. package/relay-hooks/useFragment.js.flow +31 -62
  151. package/relay-hooks/useFragmentNode.js.flow +6 -8
  152. package/relay-hooks/useIsMountedRef.js.flow +1 -1
  153. package/relay-hooks/useIsOperationNodeActive.js.flow +4 -6
  154. package/relay-hooks/useIsParentQueryActive.js.flow +4 -5
  155. package/relay-hooks/useLazyLoadQuery.js.flow +14 -16
  156. package/relay-hooks/useLazyLoadQueryNode.js.flow +20 -14
  157. package/relay-hooks/useLoadMoreFunction.js.flow +21 -30
  158. package/relay-hooks/useMemoOperationDescriptor.js.flow +6 -8
  159. package/relay-hooks/useMemoVariables.js.flow +7 -7
  160. package/relay-hooks/useMutation.js.flow +27 -27
  161. package/relay-hooks/usePaginationFragment.js.flow +39 -45
  162. package/relay-hooks/usePreloadedQuery.js.flow +14 -20
  163. package/relay-hooks/useQueryLoader.js.flow +42 -23
  164. package/relay-hooks/useRefetchableFragment.js.flow +8 -9
  165. package/relay-hooks/useRefetchableFragmentNode.js.flow +25 -33
  166. package/relay-hooks/useRelayEnvironment.js.flow +3 -5
  167. package/relay-hooks/useStaticFragmentNodeWarning.js.flow +3 -4
  168. package/relay-hooks/useSubscribeToInvalidationState.js.flow +4 -7
  169. package/relay-hooks/useSubscription.js.flow +21 -11
  170. package/lib/relay-hooks/getPaginationMetadata.js +0 -41
  171. package/lib/relay-hooks/getPaginationVariables.js +0 -67
  172. package/lib/relay-hooks/getRefetchMetadata.js +0 -36
  173. package/lib/relay-hooks/getValueAtPath.js +0 -51
  174. package/relay-hooks/getPaginationMetadata.js.flow +0 -74
  175. package/relay-hooks/getPaginationVariables.js.flow +0 -110
  176. package/relay-hooks/getRefetchMetadata.js.flow +0 -80
  177. package/relay-hooks/getValueAtPath.js.flow +0 -46
@@ -0,0 +1,53 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ * @emails oncall+relay
8
+ * @format
9
+ */
10
+ // This file is sync'd from https://github.com/facebook/react/tree/main/packages/jest-react
11
+ 'use strict';
12
+
13
+ var didWarnAboutMessageChannel = false;
14
+ var enqueueTaskImpl = null;
15
+
16
+ function enqueueTask(task) {
17
+ if (enqueueTaskImpl === null) {
18
+ try {
19
+ // read require off the module object to get around the bundlers.
20
+ // we don't want them to detect a require and bundle a Node polyfill.
21
+ var requireString = ('require' + Math.random()).slice(0, 7);
22
+ var nodeRequire = module && module[requireString]; // assuming we're in node, let's try to get node's
23
+ // version of setImmediate, bypassing fake timers if any.
24
+
25
+ enqueueTaskImpl = nodeRequire.call(module, 'timers').setImmediate;
26
+ } catch (_unused) {
27
+ // we're in a browser
28
+ // we can't use regular timers because they may still be faked
29
+ // so we try MessageChannel+postMessage instead
30
+ enqueueTaskImpl = function enqueueTaskImpl(callback) {
31
+ if (process.env.NODE_ENV !== "production") {
32
+ if (didWarnAboutMessageChannel === false) {
33
+ didWarnAboutMessageChannel = true;
34
+
35
+ if (typeof MessageChannel === 'undefined') {
36
+ console.error('This browser does not have a MessageChannel implementation, ' + 'so enqueuing tasks via await act(async () => ...) will fail. ' + 'Please file an issue at https://github.com/facebook/react/issues ' + 'if you encounter this warning.');
37
+ }
38
+ }
39
+ }
40
+ /*global MessageChannel*/
41
+
42
+
43
+ var channel = new MessageChannel();
44
+ channel.port1.onmessage = callback;
45
+ channel.port2.postMessage(undefined);
46
+ };
47
+ }
48
+ }
49
+
50
+ return enqueueTaskImpl(task);
51
+ }
52
+
53
+ module.exports = enqueueTask;
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ Object.defineProperty(exports, "act", {
7
+ enumerable: true,
8
+ get: function get() {
9
+ return _internalAct.act;
10
+ }
11
+ });
12
+
13
+ var _internalAct = require("./internalAct");
@@ -0,0 +1,115 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ * @emails oncall+relay
8
+ * @format
9
+ */
10
+
11
+ /* global jest */
12
+ // This file is sync'd from https://github.com/facebook/react/tree/main/packages/jest-react
13
+ // This version of `act` is only used by our tests. Unlike the public version
14
+ // of `act`, it's designed to work identically in both production and
15
+ // development. It may have slightly different behavior from the public
16
+ // version, too, since our constraints in our test suite are not the same as
17
+ // those of developers using React — we're testing React itself, as opposed to
18
+ // building an app with React.
19
+ 'use strict';
20
+
21
+ var enqueueTask = require('./enqueueTask');
22
+
23
+ var Scheduler = require('scheduler/unstable_mock'); // The subset of a Promise that React APIs rely on. This resolves a value.
24
+ // This doesn't require a return value neither from the handler nor the
25
+ // then function.
26
+
27
+
28
+ var actingUpdatesScopeDepth = 0;
29
+
30
+ function act(scope) {
31
+ if (Scheduler.unstable_flushAllWithoutAsserting === undefined) {
32
+ throw Error('This version of `act` requires a special mock build of Scheduler.');
33
+ }
34
+
35
+ if (setTimeout._isMockFunction !== true) {
36
+ throw Error("This version of `act` requires Jest's timer mocks " + '(i.e. jest.useFakeTimers).');
37
+ }
38
+
39
+ var previousActingUpdatesScopeDepth = actingUpdatesScopeDepth;
40
+ actingUpdatesScopeDepth++;
41
+
42
+ var unwind = function unwind() {
43
+ actingUpdatesScopeDepth--;
44
+
45
+ if (process.env.NODE_ENV !== "production") {
46
+ if (actingUpdatesScopeDepth > previousActingUpdatesScopeDepth) {
47
+ // if it's _less than_ previousActingUpdatesScopeDepth, then we can
48
+ // assume the 'other' one has warned
49
+ console.error('You seem to have overlapping act() calls, this is not supported. ' + 'Be sure to await previous act() calls before making a new one. ');
50
+ }
51
+ }
52
+ }; // TODO: This would be way simpler if 1) we required a promise to be
53
+ // returned and 2) we could use async/await. Since it's only our used in
54
+ // our test suite, we should be able to.
55
+
56
+
57
+ try {
58
+ var thenable = scope();
59
+
60
+ if (typeof thenable === 'object' && thenable !== null && typeof thenable.then === 'function') {
61
+ return {
62
+ then: function then(resolve, reject) {
63
+ thenable.then(function () {
64
+ flushActWork(function () {
65
+ unwind();
66
+ resolve();
67
+ }, function (error) {
68
+ unwind();
69
+ reject(error);
70
+ });
71
+ }, function (error) {
72
+ unwind();
73
+ reject(error);
74
+ });
75
+ }
76
+ };
77
+ } else {
78
+ try {
79
+ // TODO: Let's not support non-async scopes at all in our tests. Need to
80
+ // migrate existing tests.
81
+ var didFlushWork;
82
+
83
+ do {
84
+ didFlushWork = Scheduler.unstable_flushAllWithoutAsserting();
85
+ } while (didFlushWork);
86
+ } finally {
87
+ unwind();
88
+ }
89
+ }
90
+ } catch (error) {
91
+ unwind();
92
+ throw error;
93
+ }
94
+ }
95
+
96
+ function flushActWork(resolve, reject) {
97
+ // Flush suspended fallbacks
98
+ // $FlowFixMe: Flow doesn't know about global Jest object
99
+ jest.runOnlyPendingTimers();
100
+ enqueueTask(function () {
101
+ try {
102
+ var didFlushWork = Scheduler.unstable_flushAllWithoutAsserting();
103
+
104
+ if (didFlushWork) {
105
+ flushActWork(resolve, reject);
106
+ } else {
107
+ resolve();
108
+ }
109
+ } catch (error) {
110
+ reject(error);
111
+ }
112
+ });
113
+ }
114
+
115
+ exports.act = act;
package/lib/legacy.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Copyright (c) Facebook, Inc. and its affiliates.
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
3
  *
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ *
8
+ * @emails oncall+relay
9
+ * @format
10
+ */
11
+ 'use strict';
12
+
13
+ var RelayEnvironmentProvider = require('../relay-hooks/RelayEnvironmentProvider');
14
+
15
+ var useRelayActorEnvironment = require('./useRelayActorEnvironment');
16
+
17
+ var React = require('react');
18
+
19
+ function ActorChange(props) {
20
+ var actorEnvironment = useRelayActorEnvironment(props.actorChangePoint.__viewer);
21
+ var getEnvironmentForActor = React.useCallback(function (actorIdentifier) {
22
+ return actorEnvironment.multiActorEnvironment.forActor(actorIdentifier);
23
+ }, [actorEnvironment]);
24
+ return /*#__PURE__*/React.createElement(RelayEnvironmentProvider, {
25
+ environment: actorEnvironment,
26
+ getEnvironmentForActor: getEnvironmentForActor
27
+ }, props.children(props.actorChangePoint.__fragmentRef, props.actorChangePoint.__viewer));
28
+ }
29
+
30
+ module.exports = ActorChange;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ *
8
+ * @emails oncall+relay
9
+ * @format
10
+ */
11
+ 'use strict';
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ * @emails oncall+relay
8
+ *
9
+ * @format
10
+ */
11
+ // flowlint ambiguous-object-type:error
12
+ 'use strict';
13
+
14
+ var invariant = require('invariant');
15
+
16
+ var _require = require('react'),
17
+ useContext = _require.useContext;
18
+
19
+ var ReactRelayContext = require('react-relay/ReactRelayContext');
20
+
21
+ function useRelayActorEnvironment(actorIdentifier) {
22
+ var context = useContext(ReactRelayContext);
23
+ !(context != null) ? process.env.NODE_ENV !== "production" ? invariant(false, 'useRelayActorEnvironment: Expected to have found a Relay environment provided by ' + 'a `RelayEnvironmentProvider` component. ' + 'This usually means that useRelayActorEnvironment was used in a ' + 'component that is not a descendant of a `RelayEnvironmentProvider`. ' + 'Please make sure a `RelayEnvironmentProvider` has been rendered somewhere ' + 'as a parent or ancestor of your component.') : invariant(false) : void 0;
24
+ var getEnvironmentForActor = context.getEnvironmentForActor;
25
+ !(getEnvironmentForActor != null) ? process.env.NODE_ENV !== "production" ? invariant(false, 'useRelayActorEnvironment: Expected to have a function `getEnvironmentForActor`.' + 'This usually means that `RelayEnvironmentProvider`. was not properly set up for use in the ' + 'multi actor application. Please make sure the provider has defined a `getEnvironmentForActor`.') : invariant(false) : void 0;
26
+ return getEnvironmentForActor(actorIdentifier);
27
+ }
28
+
29
+ module.exports = useRelayActorEnvironment;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Copyright (c) Facebook, Inc. and its affiliates.
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
3
  *
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Copyright (c) Facebook, Inc. and its affiliates.
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
3
  *
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.
@@ -13,16 +13,16 @@
13
13
 
14
14
  var ProfilerContext = require('./ProfilerContext');
15
15
 
16
- var React = require('react');
17
-
18
16
  var useRelayEnvironment = require('./useRelayEnvironment');
19
17
 
20
- var warning = require("fbjs/lib/warning");
18
+ var React = require('react');
21
19
 
22
20
  var _require = require('react'),
23
21
  useContext = _require.useContext,
24
22
  useEffect = _require.useEffect;
25
23
 
24
+ var warning = require("fbjs/lib/warning");
25
+
26
26
  function EntryPointContainer(_ref) {
27
27
  var entryPointReference = _ref.entryPointReference,
28
28
  props = _ref.props;
@@ -1,5 +1,5 @@
1
1
  /**
2
- * Copyright (c) Facebook, Inc. and its affiliates.
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
3
  *
4
4
  * This source code is licensed under the MIT license found in the
5
5
  * LICENSE file in the root directory of this source tree.