From 8f30dd263b687948a0c4b9d5d93344d3353cc722 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 2 Apr 2015 20:49:03 +0000 Subject: [PATCH] update website --- docs/nativemodulesios.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/nativemodulesios.html b/docs/nativemodulesios.html index 29822f846ff..8211e72d918 100644 --- a/docs/nativemodulesios.html +++ b/docs/nativemodulesios.html @@ -17,7 +17,9 @@ CalendarManager.{ RCT_EXPORT(addEvent); NSDate *date = [NSDate dateWithTimeIntervalSince1970:secondsSinceUnixEpoch]; -}

As CalendarManager.addEvent method gets more and more complex, the number of arguments will grow. Some of them might be optional. In this case it's worth considering changing the API a little bit to accept a dictionary of event attributes, like this:

- (void)addEventWithName:(NSString *)name details:(NSDictionary *)details +}

As CalendarManager.addEvent method gets more and more complex, the number of arguments will grow. Some of them might be optional. In this case it's worth considering changing the API a little bit to accept a dictionary of event attributes, like this:

#import "RCTConvert.h" + +- (void)addEventWithName:(NSString *)name details:(NSDictionary *)details { RCT_EXPORT(addEvent); NSString *location = [RCTConvert NSString:details[@"location"]]; // ensure location is a string