naoufal / react-native-accordion

An Accordion Component for React Native
https://www.npmjs.com/package/react-native-accordion
437 stars 101 forks source link

Text component with dynamic content inside Accordion #43

Closed Proberts closed 7 years ago

Proberts commented 7 years ago

Do I need to do anything special for a with dynamic content (.children) inside an ?

I have something like this:

{this.props.stateVar}

Where stateVar is a dynamic string set by a Redux reducer. If is outside the it updates as expected. If it is inside it doesn't get triggered for an update. I've tried adding dummy props, wrapping the with another component that uses a prop to set the content string, and forcing re-render of the via a ref, but can't seem to get it to update the contents. Doesn't seem to matter if the Accordion is open or closed. Any help is appreciated.

As an aside, I'm new to Github - is this the right place to ask questions or is 'issues' only for bugs?

Proberts commented 7 years ago

This is no longer an issue. I'm not sure which fixed it: Upgrading to RN 0.36.1 or deleting node_modules and doing 'npm install'.