react的hooks中,useReducer的第三个参数有什么用?initialArg和init的区别。
1条回答 默认 最新
CSDN专家-showbo 2021-11-10 11:50关注As far as I can experiment, the init function as third arg is a transformer of the initialState.
e文,题主参考下
https://stackoverflow.com/questions/59041341/whats-the-purpose-of-the-3rd-argument-in-usereducer本回答被题主选为最佳回答 , 对您是否有帮助呢?评论 打赏 举报解决 1无用