-
Notifications
You must be signed in to change notification settings - Fork 37
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
Feature Request(farrow-client-api): custom fetcher #142
Comments
|
Looks yes. But not functional. 👀 api.setFetcher(fetcjer) or api.addTodo({/** input data */}, { fetcher: customFetcher }) ? |
We can follow the principle of
Use functional style in JavaScript/TypeScript is given its cost. We can gain more benefits at the core of our logic to cover the cost. So, in my opinion, Of course, an elegant functional approach solve the same problem perfectly will be the best way. |
And |
When people want to add a specific header to a single request(calling), seems that only |
Yes, it makes sense.
|
#96 #98
At #98, We can do
const myApiPipeline = createApiPipeline({ fetcher })
. But we ignore another case: code generation at client. In the generated code. the pipeline has been created already, So we still can not custom fetcher at this case.For now, we can pass the
batch
options when calling generated function. Could we add new option to theinvoke
function of api pipeline? Or is there any else way to solve this problem?Expect
The text was updated successfully, but these errors were encountered: