Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support converting components wrapped in Redux connect #2

Open
jmeberst opened this issue Oct 13, 2017 · 1 comment
Open

Support converting components wrapped in Redux connect #2

jmeberst opened this issue Oct 13, 2017 · 1 comment

Comments

@jmeberst
Copy link

I'm trying to convert a component that's wrapped in the connect method from react-redux.

The error I'm getting is cannot call a class as a function in Route.js

var props = processProps(tree.props); if (type === 'function') { return convertComponent(tree.type(props), key); }

@PaulLeCam
Copy link
Contributor

Hi, sorry for the late reply, I haven't been focusing on this lib since it got implemented in our project.

Yes this kind of use-case it not supported, this library is meant to convert an abstract tree of components defined as strings or simple functions, not really to support "real" React components, thought that could be a good improvement.
I think the easiest in your case is to provide a custom processMeta function in the options to output the relevant component name and the type as string so it can be simply handled.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants