Skip to content

Commit

Permalink
fix: update nativeInterface default export to support bridgeless mode (
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrieldonadel committed Feb 27, 2024
1 parent 6687ea2 commit 950410b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/internal/nativeInterface.ts
Expand Up @@ -28,8 +28,7 @@ If none of these fix the issue, please open an issue on the Github repository: h
* JavaScript code and the tests
*/
let nativeEventEmitter: NativeEventEmitter | null = null;
export default {
...RNCNetInfo,
const nativeInterface = Object.assign(RNCNetInfo, {
get eventEmitter(): NativeEventEmitter {
if (!nativeEventEmitter) {
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
Expand All @@ -40,4 +39,5 @@ export default {
/// @ts-ignore
return nativeEventEmitter;
},
};
});
export default nativeInterface;

0 comments on commit 950410b

Please sign in to comment.