Skip to content
New issue

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

Image组件是否可以使用forwardRef定义,目前无法传入ref #372

Open
SimerW opened this issue Oct 9, 2024 · 1 comment
Open

Comments

@SimerW
Copy link

SimerW commented Oct 9, 2024

import Image from 'rc-image';

export const MyComponent = () {
const ref = useRef(null)
return <Image src="XXX" ref={ref}
}

上述场景中想要传入ref到Image组件内部,绑定在img元素上,但是目前无法实现

@afc163
Copy link
Member

afc163 commented Oct 10, 2024

PR is welcome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants