creamy-piano-53628
04/17/2024, 10:12 PMsetPolyfills
is not very good.creamy-piano-53628
04/17/2024, 10:19 PMconst storage = new MMKV();
setPolyfills({
// Required when using built-in feature loading and Node 17 or lower
fetch: require("react-native-fetch-polyfill"),
// Optional, can make feature rollouts faster
EventSource: require("react-native-event-source"),
// Optional, can reduce startup times by persisting cached feature flags
localStorage: {
// Example using Redis
getItem: (key) => storage.getString(key) ?? null,
setItem: (key, value) => storage.set(key, value),
},
});
This does not seem to work, it does not fetch any flags (every flag is off/undefined)creamy-piano-53628
04/17/2024, 10:21 PMwide-cpu-11577
04/23/2024, 11:15 AMcreamy-piano-53628
04/23/2024, 5:37 PMfresh-football-47124
fresh-football-47124
fresh-football-47124
wide-cpu-11577
04/24/2024, 6:28 AMcreamy-piano-53628
04/26/2024, 12:49 PMcreamy-piano-53628
04/26/2024, 12:49 PMcreamy-piano-53628
04/26/2024, 12:49 PMcreamy-piano-53628
04/26/2024, 12:50 PMconst storage = new MMKV();
setPolyfills({
// Required when using built-in feature loading and Node 17 or lower
fetch: require("react-native-fetch-polyfill"),
// Optional, can make feature rollouts faster
EventSource: require("react-native-event-source"),
// Optional, can reduce startup times by persisting cached feature flags
localStorage: {
// Example using Redis
getItem: (key) => storage.getString(key) ?? null,
setItem: (key, value) => storage.set(key, value),
},
});
I tried this, but it does not work. It should be simple to setup, we just need the correct params for the polyfills.