1 | var _a;
|
2 | import "./utils/assertEnvironment";
|
3 | import { unstable_batchedUpdates as batch } from "./utils/reactBatchedUpdates";
|
4 | import { observerBatching } from "./utils/observerBatching";
|
5 | import { useDeprecated } from "./utils/utils";
|
6 | import { useObserver as useObserverOriginal } from "./useObserver";
|
7 | import { enableStaticRendering } from "./staticRendering";
|
8 | import { observerFinalizationRegistry } from "./utils/observerFinalizationRegistry";
|
9 | observerBatching(batch);
|
10 | export { isUsingStaticRendering, enableStaticRendering } from "./staticRendering";
|
11 | export { observer } from "./observer";
|
12 | export { Observer } from "./ObserverComponent";
|
13 | export { useLocalObservable } from "./useLocalObservable";
|
14 | export { useLocalStore } from "./useLocalStore";
|
15 | export { useAsObservableSource } from "./useAsObservableSource";
|
16 | export { observerFinalizationRegistry as _observerFinalizationRegistry };
|
17 | export var clearTimers = (_a = observerFinalizationRegistry["finalizeAllImmediately"]) !== null && _a !== void 0 ? _a : (function () { });
|
18 | export function useObserver(fn, baseComponentName) {
|
19 | if (baseComponentName === void 0) { baseComponentName = "observed"; }
|
20 | if ("production" !== process.env.NODE_ENV) {
|
21 | useDeprecated("[mobx-react-lite] 'useObserver(fn)' is deprecated. Use `<Observer>{fn}</Observer>` instead, or wrap the entire component in `observer`.");
|
22 | }
|
23 | return useObserverOriginal(fn, baseComponentName);
|
24 | }
|
25 | export { isObserverBatched, observerBatching } from "./utils/observerBatching";
|
26 | export function useStaticRendering(enable) {
|
27 | if ("production" !== process.env.NODE_ENV) {
|
28 | console.warn("[mobx-react-lite] 'useStaticRendering' is deprecated, use 'enableStaticRendering' instead");
|
29 | }
|
30 | enableStaticRendering(enable);
|
31 | }
|
32 |
|
\ | No newline at end of file |