Invalid prop: type check failed for prop "pageSize". Expected Number with value 10, got String with value "10".
时间: 2023-08-26 09:18:25 浏览: 175
这个错误的原因是属性pageSize的数据类型不匹配。期望的数据类型是Number,但传入的值是String。具体来说,报错信息中期望的值是10,但实际传入的值是"10"。根据引用和引用的解释,这个错误可能是因为没有给total赋初始值导致的。给total赋初始值后,问题应该会得到解决。另外,引用中提到如果不使用v-bind将page-size属性绑定,则会将3解析为字符串,这可能会影响后续正确的代码运行。这可能是造成这个错误的另一个原因。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* *3* [记一次vue数据类型报错,控制台显示需要int类型,而传输了string类型](https://blog.csdn.net/qq_45928041/article/details/123192369)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
- *2* [[Vue warn]: Invalid prop: type check failed for prop “pageSize“. Expected Number with value NaN](https://blog.csdn.net/aabb12345687/article/details/131714488)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v92^chatsearchT3_1"}}] [.reference_item style="max-width: 50%"]
[ .reference_list ]
阅读全文