React报错之Cannot find name

正文从这开始~ .tsx扩展名 为了在React TypeScript中解决Cannot find name报错,我们需要在使用JSX文件时使用.tsx扩展名,在你的tsconfig.json文件中把jsx设置为react-jsx ,并确保为你的应用程序安装所有必要的@types包。 下面是在名为A

你可能感兴趣的:(React报错之Cannot find name)