We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
getting typescript error on attempting to add non-explicitly defined props in to component despite docs indicating that it is possible
Any other props will be passed down to the element. This way, you can e.g. add an alt attribute to the image.
Type '{ src: string; alt: string; }' is not assignable to type 'IntrinsicAttributes & IntrinsicClassAttributes<Magnifier> & Pick<Readonly<Props> & Readonly<{ children?: ReactNode; }>, "children" | "src"> & Partial<...> & Partial<...>'. Property 'alt' does not exist on type 'IntrinsicAttributes & IntrinsicClassAttributes<Magnifier> & Pick<Readonly<Props> & Readonly<{ children?: ReactNode; }>, "children" | "src"> & Partial<...> & Partial<...>'.
looking at interface Props defined in /src/Magnifier.tsx is it possible that adding a [key: string]?: HTMLAttributes<T> would address the issue?
interface Props
/src/Magnifier.tsx
[key: string]?: HTMLAttributes<T>
The text was updated successfully, but these errors were encountered:
No branches or pull requests
getting typescript error on attempting to add non-explicitly defined props in to component despite docs indicating that it is possible
looking at
interface Props
defined in/src/Magnifier.tsx
is it possible that adding a[key: string]?: HTMLAttributes<T>
would address the issue?The text was updated successfully, but these errors were encountered: