react-bluekit icon indicating copy to clipboard operation
react-bluekit copied to clipboard

Context doesn't seem to always work

Open sbkn opened this issue 7 years ago • 1 comments

So I'm trying to use react-bluekit with redux-form, which utilizes context to propagate a decorated component and it's props to children.

I've wrapped the whole <BlueKit/> component in a connected form and rendering the initial view works flawlessly. When going to any specific component via sidebar though, context seems to get lost and redux-form throws at

if (!context._reduxForm) {
   throw new Error('Field must be inside a component decorated with reduxForm()');
}

How comes?

sbkn avatar Mar 24 '17 16:03 sbkn

This is strange behaviour. Bluekit has no router insideso context should stay without any changes. Have you tried for example crete component with displaying context? And if it works? We are using bluekit inside of redux provider without any problems. And that should be same use case as you have it

ondrejbartas avatar Mar 28 '17 18:03 ondrejbartas