Typescript "this" 隐式具有类型 "any",因为它没有类型注释 'this' implicitly has type
问题:"this"隐式具有类型"any",因为它没有类型注释'this'implicitlyhastype'any'becauseitdoesnothaveatypeannotation解决方案:将this放在函数形参上声明即可,使用的时候this不会干扰形参传入顺序constDemo:React.FC=()=>{constfn=()=>{