-
Notifications
You must be signed in to change notification settings - Fork 52
Open
Description
I got into this situation where my React component requires more than one prop.
One way to solve it was through adding two @resolve calls with two different callbacks.
@resolve("propA", function() { remoteCall() .... return response.propA; })
@resolve("propB", function() { remoteCall().... return response.propB; })
However, I'd like to be able to collect multiple props in one single callback, and hence save one remote call.
I hacked something together that allows me to do something like:
@resolve("{propA, propB}", function() {
remoteCall() ...
return { response.propA, response.propB };
})- Does this make sense?
- Is there any other way to do this?
- Does this go against react-resolver's philosophy?
@ericclemmons: I can put together a Pull Request if you think this makes sense.
Metadata
Metadata
Assignees
Labels
No labels