Skip to content

Commit

Permalink
Register method
Browse files Browse the repository at this point in the history
  • Loading branch information
shp7724 committed May 13, 2024
1 parent 982fbe5 commit 5238669
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@

@interface RCT_EXTERN_MODULE(RNEventEmitter, RCTEventEmitter)
RCT_EXTERN_METHOD(supportedEvents)
RCT_EXTERN_METHOD(sendEventToNative:(NSString *)name payload:(NSDictionary *)payload)
@end
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class RNEventEmitter: RCTEventEmitter {
events
}

@objc func sendEventToNative(name: String, payload: [AnyHashable: Any]? = nil) {
@objc func sendEventToNative(_ name: String, payload: [AnyHashable: Any]? = nil) {
if let registerEvent = RegisterEvent(rawValue: name) {
registerEventSubject.value = registerEvent
}
Expand Down

0 comments on commit 5238669

Please sign in to comment.