-
Hi, I'm using the package in one of my projects, and I'm having some issue I'm trying to solve for a while now. But the code suggested in the example is already in use in my code. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
Can you provide an isolated repro repository? It would be the best option and I could find a solution quickly. Otherwise, I need a complete code snippet and some info. React version? Browser version which fails? Based on the code provided earlier, you're trying to do something like this: Object.keys(obj).map((key) => {
// ...
const Item = <Item>{({ ref, open }) => <img ref={ref} onClick={open} />}</Item>
// ...
}) Can you provide exactly what you returning from the map callback? Do you use an Item component outside of map callback somewhere? |
Beta Was this translation helpful? Give feedback.
Can you provide an isolated repro repository? It would be the best option and I could find a solution quickly.
Otherwise, I need a complete code snippet and some info. React version? Browser version which fails?
This example works well in that browser? https://dromru.github.io/react-photoswipe-gallery/?path=/story/gallery--simple
Based on the code provided earlier, you're trying to do something like this:
Can you provide exactly what you returning from the map callback?
Do you use an Item component outside of map callback somewhere?