Hi, I just saw that the ref usage has changed with 0a1fa23. I don't understand how I am supposed to use Callback Refs now. Does someone has a simple example please ?
t
turansky
07/25/2021, 8:46 PM
Copy code
val onContainer = useRefCallback<HTMLDivElement> { container ->
// do job
}
div {
ref = onContainer
}
turansky
07/25/2021, 8:50 PM
Copy code
// UNSAFE
div {
ref = RefCallback<HTMLDivElement> {
it // div?
}
}