react-native-gridview icon indicating copy to clipboard operation
react-native-gridview copied to clipboard

itemsPerRow not working

Open piloulac opened this issue 8 years ago • 0 comments

Hello!

I'm trying to use your framework and it appears that the prop itemsPerRow doesn't work for me.. Here is my calling function:

_renderGridView() {
        if(this.state.dataSource){
            ...
            return (
                <GridView
                    dataSource={dataSource}
                    itemsPerRow={2}
                    padding={4}
                    renderItem={(item, sectionID, rowID, itemIndex, itemID) => {
                        return (
                           <ArtistItem artist={item}/>
                        );
                      }}
                />
            );
        }
    }

But they are every time 1 per row.. Even if I reduce the width of each element they stay on the left of the screen 1 per row.

Thank you in advance if you have an idea!

piloulac avatar Sep 15 '17 10:09 piloulac