mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-05-18 12:49:24 +00:00
[change] Add usePlatformMethods to implement instance methods
A hook equivalent for implementing "native methods" on refs to elements backed by function components.
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
/* eslint-env jasmine, jest */
|
||||
|
||||
// JSDOM doesn't implement ResizeObserver
|
||||
class ResizeObserver {
|
||||
disconnect() {}
|
||||
observe() {}
|
||||
unobserve() {}
|
||||
}
|
||||
|
||||
window.ResizeObserver = ResizeObserver;
|
||||
Reference in New Issue
Block a user