摘要: 1 getAll(id){ 2 axios.defaults.withCredentials=true; 3 axios.get(`$请求地址}`) 4 .then(result => { 5 console.info( result ); 6 }).catch(error => { 7 conso 阅读全文
posted @ 2020-03-23 20:57 无人问及 阅读(6991) 评论(0) 推荐(0) 编辑
摘要: 1 if判断,满足条件才渲染 1 if(x < 2) return <div>页面</div> 2 return null ; 2 三元运算符 1 return ( 2 <div> 3 { x <2 4 ? <ItemEdit item={item} /> 5 : <ItemView item={i 阅读全文
posted @ 2020-03-23 09:40 无人问及 阅读(118) 评论(0) 推荐(0) 编辑