This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, {Suspense, useRef, useState} from 'react'; | |
import {Button, SafeAreaView, View, Text, ScrollView} from 'react-native'; | |
let cache = new Map(); | |
function fetch(key) { | |
if (!cache.has(key)) { | |
cache.set(key, getData(key)); | |
} | |
return cache.get(key); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react'; | |
import {Button, SafeAreaView, Text} from 'react-native'; | |
import {Image} from 'expo-image'; | |
import Animated from 'react-native-reanimated'; | |
const AnimatedImage = Animated.createAnimatedComponent(Image); | |
const SQUARE_POST_HEIGHT = 200; | |
const SQUARE_POST_WIDTH = 200; | |
const thumbnail_url = |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Freeze } from 'react-freeze'; | |
function SomeComponent({ shouldSuspendRendering }) { | |
return ( | |
<Freeze freeze={shouldSuspendRendering}> | |
<MyOtherComponent /> | |
</Freeze> | |
); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Freeze } from 'react-freeze'; | |
function SomeComponent({ shouldSuspendeRendering }) { | |
return ( | |
<Freeze freeze={shouldSuspendeRendering}> | |
<MyOtherComponent /> | |
</Freeze> | |
); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function SomeComponent({ shouldSuspendeRendering }) { | |
return ( | |
<Freeze freeze={shouldSuspendeRendering}> | |
<MyOtherComponent /> | |
</Freeze> | |
); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { enableFreeze } from 'react-native-screens'; | |
enableFreeze(true); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { ReactElement, useState } from "react"; | |
import Animated, { | |
useAnimatedRef, | |
useAnimatedScrollHandler, | |
useSharedValue, | |
} from "react-native-reanimated"; | |
import Item from "./Item"; | |
import { COL, Positions, SIZE } from "./Config"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { ReactNode, RefObject, useEffect } from "react"; | |
import { Dimensions, StyleSheet } from "react-native"; | |
import Animated, { | |
useAnimatedGestureHandler, | |
useAnimatedStyle, | |
useAnimatedReaction, | |
withSpring, | |
scrollTo, | |
withTiming, | |
useSharedValue, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Animated, { | |
useSharedValue, | |
useAnimatedReaction, | |
withTiming, | |
withDecay, | |
withRepeat, | |
withSequence, | |
withSpring, | |
withDelay, | |
useAnimatedRef, |
NewerOlder