Skip to content

Codegen Missing Features #91

Answered by dmytrorykun
cipolleschi asked this question in Q&A
Discussion options

You must be logged in to vote

@hannojg I'll copy my answer from a different discussion:

The Command abstraction is a way to tell a native component to do something bypassing the renderer. You should not expect any return value from it. The return value from a command generally may depend on many things other than component itself. This makes such component non-composable. This breaks one of React's fundamental principles. This is also the reason why it only accepts primitive types. We may add some more capabilities in the future, but there are currently no plans for that.

I would recommend to try finding a way to implement this behaviour using Native Modules.

Replies: 11 comments 24 replies

Comment options

You must be logged in to vote
0 replies

This comment has been hidden.

@ZihanChen-MSFT
Comment options

@cipolleschi
Comment options

@troZee
Comment options

This comment has been hidden.

@ZihanChen-MSFT
Comment options

@ZihanChen-MSFT
Comment options

Comment options

You must be logged in to vote
8 replies
@cipolleschi
Comment options

@matinzd
Comment options

@mym0404
Comment options

@Fa7
Comment options

@cipolleschi
Comment options

Comment options

You must be logged in to vote
0 replies

This comment has been hidden.

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
3 replies
@cipolleschi
Comment options

@jerielng
Comment options

@cipolleschi
Comment options

Comment options

You must be logged in to vote
5 replies
@oliviermartin
Comment options

@cortinico
Comment options

@oliviermartin
Comment options

@cortinico
Comment options

@dmytrorykun
Comment options

Comment options

You must be logged in to vote
3 replies
@hannojg
Comment options

@hannojg
Comment options

@dmytrorykun
Comment options

Answer selected by hannojg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet