()
| 19 | }; |
| 20 | |
| 21 | export const RemoteConfig = () => { |
| 22 | const { status, data: remoteConfigInstance } = useInitRemoteConfig(async (firebaseApp) => { |
| 23 | const remoteConfig = getRemoteConfig(firebaseApp); |
| 24 | remoteConfig.settings = { |
| 25 | minimumFetchIntervalMillis: 10000, |
| 26 | fetchTimeoutMillis: 10000, |
| 27 | }; |
| 28 | await fetchAndActivate(remoteConfig); |
| 29 | return remoteConfig; |
| 30 | }); |
| 31 | |
| 32 | if (status === 'loading') { |
| 33 | return <LoadingSpinner />; |
| 34 | } |
| 35 | |
| 36 | return ( |
| 37 | <RemoteConfigProvider sdk={remoteConfigInstance}> |
| 38 | <RcString messageKey="message" /> |
| 39 | </RemoteConfigProvider> |
| 40 | ); |
| 41 | }; |
nothing calls this directly
no test coverage detected