Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
import { AppRegistry } from 'react-native';
import { getStorybookUI, configure } from '@storybook/react-native'; // eslint-disable-line
import RNBootSplash from 'react-native-bootsplash';
import 'react-native-gesture-handler';
RNBootSplash.hide();
// import stories
configure(() => {
require('./stories');
}, module);
// Refer to https://github.com/storybooks/storybook/tree/master/app/react-native#start-command-parameters
// To find allowed options for getStorybookUI
const StorybookUIRoot = getStorybookUI({});
// If you are using React Native vanilla and after installation you don't see your app name here, write it manually.
// If you use Expo you can safely remove this line.
AppRegistry.registerComponent('RocketChatRN', () => StorybookUIRoot);
export default StorybookUIRoot;
let init = async () => {
BootSplash.hide();
// You can uncomment this line to add a delay on app startup
// let data = await fakeApiCallWithoutBadNetwork(3000);
let useNativeDriver = true;
Animated.stagger(250, [
Animated.spring(translateY.current, { useNativeDriver, toValue: -50 }),
Animated.spring(translateY.current, {
useNativeDriver,
toValue: Dimensions.get("window").height,
}),
]).start();
Animated.timing(opacity.current, {
useNativeDriver,
public componentDidMount(): void {
I18n.init();
BootSplash.hide();
}
useMountEffect(() => {
RNBootSplash.hide({ fade: true })
})
return null