Closed Dan-Wood closed 4 years ago
Is it possible to just return a map() of instead of a wrapping
`
))} </div>
To
` {this.state.media.map((media, index) => (
))}
It gives the user more control over the wrapping elements. Where I was to set each 's class to "col-6 col-lg-4" (Bootstrap) wrapping it in a
In React you need to return a single root element so I don't expect to be able to do that.
If you include the markup you want to wrap it in I can have a think about how to make it configureable. e.g.
<row> <Media> <Media> <Media> </row> <row> <Media> ...
Alternatively you could use Instagram.getFeed(username) # => [<MediaObject>] Reference: https://github.com/jamesmoriarty/react-instagram-authless-feed/blob/master/src/lib/Instagram.js
Instagram.getFeed(username) # => [<MediaObject>]
Is it possible to just return a map() of instead of a wrapping
`
`
To
` {this.state.media.map((media, index) => (
`
It gives the user more control over the wrapping elements. Where I was to set each's class to "col-6 col-lg-4" (Bootstrap) wrapping it in a |
In React you need to return a single root element so I don't expect to be able to do that.
If you include the markup you want to wrap it in I can have a think about how to make it configureable. e.g.
Alternatively you could use
Instagram.getFeed(username) # => [<MediaObject>]
Reference: https://github.com/jamesmoriarty/react-instagram-authless-feed/blob/master/src/lib/Instagram.js