admin管理员组

文章数量:1122846

I am having an issue when I want to view a react component's definition and occurrences in my create-react-app project in VSCode. It keeps showing the index.d.ts file (node_modules/@types/react/ts5.0/index.d.ts) has the first option. The file links to this:

        (
            props: P,
            /**
             * @deprecated
             *
             * @see {@link .html#referencing-context-in-lifecycle-methods React Docs}
             */
            deprecatedLegacyContext?: any,
        ): ReactElement<any, any> | null;

How can I prevent this file from showing when I command-click on my custom react component?

本文标签: