Open
Description
Is your feature request related to a problem? Please describe.
When creating a model, you might want to expose reusable hooks with default options:
const useMultiTweets = () => useMulti({model: Tweets})
It is difficult to write such a closure however, because of the parameters structure.
Describe the solution you'd like
const useMultiTweets = makeUseMulti<TweetType>({model: Tweets})
In this example, makeUseMulti
handles the merge of paremeters, so that useMultiTweets
has the exact same APi as useMulti
, but uses Tweets as the default model.
Of course, do the same for other hooks.