cost 97 ms
反應 typescript - 元素隱式具有“任何”類型,因為使用國家標志圖標時,“字符串”類型的表達式不能用於索引類型

[英]react typescript - Element implicitly has an 'any' type because expression of type 'string' can't be used to index type when using country-flag-icons

應用程序.tsx 個人.tsx 在行 , typescript 在這里拋出錯誤 有可能修復嗎? 代碼沙盒 https://codesandbox.io/s/react-typescript-forked-j05w6x?file=/src/Person.tsx ...


排序:
質量:
 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM