Typescript inference of sibling function's generic arguments

前端 未结 0 1978
没有蜡笔的小新
没有蜡笔的小新 2020-12-12 07:07

I want to achieve the following inference:

const query = useQuery({
  action: fetchBooks,
  variables: [1, \'2\'], // inferred from fetchBooks argument types
         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题