[React Native] ๋ฒํผ์ ํด๋ฆญํ์ฌ ํ์ฌ ํ๋ฉด์ ์บก์ฒํด๋ณด์โ
ยท
Frontend/React Native
Install $ yarn add react-native-view-shot Import import ViewShot from 'react-native-view-shot'; Code import ViewShot from 'react-native-view-shot'; function App() { const ref = useRef(); const captureScreen = () => { ref.current.capture().then((uri) => { console.log('capture complete...', uri); }); }; return ( // ํ๋ฉด ์บก์ฒ๋ ๋ถ๋ถ์ ViewShot ์ปดํฌ๋ํธ๋ก ๊ฐ์ธ์ค๋คโโ ํ๋ฉด ์บก์ฒ ); } ๐ก useRef useRef๋ ํน์ ์ปดํฌ๋ํธ๋ฅผ ์ ํํ ๋ ์ฌ์ฉํ๋ ho..