数据请求
上传文件
上传文件如果手动设置了Content-Type为multipart/form-data,后端有可能会报错Failed to parse multipart servlet request; nested exception is org.apache.tomcat.util.http.fileupload.FileUploadException: the request was rejected because no multipart boundary was found 去掉手动设置的Content-Type,让浏览器自动设置multipart/form-data,因为手动设置的Content-Type没有包含boundary参数。
Vue3的一些注意问题
子组件的ref和子组件的标签名不能一样
vue
<template>
<div>
<child-component ref="childComponent"></child-component>
</div>
</template>1
2
3
4
5
2
3
4
5
如果子组件的ref和子组件的标签名一样,会警告Component is missing template or render function.,使组件不可访问

