rnc-archive / react-native-drawer-layout

A platform-agnostic drawer layout for react-native
256 stars 63 forks source link

Image not shown until any key pressed #31

Open LiuHongtao opened 7 years ago

LiuHongtao commented 7 years ago

Hi,

Image not shown until any key pressed as below. It runs well on iOS. And it's ok also if I replace DrawerLayout with DrawerLayoutAndroid.

wx20170427-150444 2x wx20170427-150539 2x

Here is the code of MainScene and Drawer.

class MainScene extends Component {
    render() {
    let navigationView = (
        <Drawer/>
    );

    return (
        <DrawerLayout
            drawerWidth={300}
            drawerPosition={DrawerLayout.positions.Left}
            renderNavigationView={() => navigationView}>
            <Text>MainScene</Text>
        </DrawerLayout>
    );
    }
}

class Drawer extends Component {
    render() {
    return (
        <View style={styles.container}>
            <Image style={styles.logo} source={youdataLogo}/>
        </View>
    );
    }
}

Thx!

DanielMSchmidt commented 7 years ago

Hey, thanks for reporting this! Would you be so kind to tell me the RN version you are using and if we speak about a local or online image? I don't know if it makes a difference, but I want to have a look into this tomorrow morning and I want to make sure that I have enough information to fix it 👍

LiuHongtao commented 7 years ago

It's local image in my case. And not only Press Key , Click Button make it happen also.

Here is the dependencies.

"dependencies": {
    "react": "16.0.0-alpha.6",
    "react-native": "0.43.4",
    "react-native-drawer-layout": "^1.3.0"
},

Thx~