Files
react-native-svg/apps/common/test/Test2148.tsx
Jakub Grzywacz b3b175a7fb feat: move examples to ./apps (#2507)
# Summary

Due to the large number of example apps in the repository, I decided to
change the structure and move all applications into an "apps" folder to
maintain a clear structure.
2024-10-25 16:12:23 +02:00

21 lines
734 B
TypeScript

import React, {useState} from 'react';
import {Text, View} from 'react-native';
import {SvgFromUri} from 'react-native-svg';
export default function App() {
const [error, setError] = useState<Error>();
return (
<View style={{flex: 1, backgroundColor: 'red', padding: 50}}>
<SvgFromUri
uri={
'https://www.google.com/url?sa=i&url=https%3A%2F%2Fwww.svgrepo.com%2Fsvg%2F5154%2Fhand-pointer&psig=AOvVaw2e3ud_ho3oPjy1VSLw0nch&ust=1717666569513000&source=images&cd=vfe&opi=89978449&ved=0CBIQjRxqFwoTCLixjuCUxIYDFQAAAAAdAAAAABAY'
}
width={24}
height={24}
onError={setError}
/>
<Text style={{marginTop: 50, color: '#fff'}}>{error?.message}</Text>
</View>
);
}