To run the example project, clone the repo, and run pod install
from the Example directory first.
IosAnalyticsDebugger is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'IosAnalyticsDebugger'
Obj-C
AnalyticsDebugger * debugger = [AnalyticsDebugger new];
Swift
let debugger = AnalyticsDebugger()
Obj-C
[debugger showBubbleDebugger];
or
[debugger showBarDebugger];
Swift
debugger.showBubble()
or
debugger.showBarDebugger()
Obj-C
[debugger hideDebugger];
Swift
debugger.hide()
Obj-C
NSMutableArray * props = [NSMutableArray new];
[props addObject:[[DebuggerProp alloc] initWithId:@"id0" withName:@"id0 event" withValue:@"value 0"]];
[props addObject:[[DebuggerProp alloc] initWithId:@"id1" withName:@"id1 event" withValue:@"value 1"]];
NSMutableArray * errors = [NSMutableArray new];
[errors addObject:[[DebuggerPropError alloc] initWithPropertyId:@"id0" withMessage:@"error in event id0"]];
[debugger publishEvent:@"Test Event" withTimestamp:[NSNumber numberWithDouble:[[NSDate date] timeIntervalSince1970]]
withProperties:props withErrors:errors];
Swift
debugger.publishEvent("Test Event", withTimestamp: NSNumber(value: NSDate().timeIntervalSince1970),
withProperties: [DebuggerProp(id: "id0", withName: "prop 0", withValue: "value 0"),
DebuggerProp(id: "id1", withName: "prop 1", withValue: "value 1")],
withErrors: [DebuggerPropError(propertyId: "id0", withMessage: "error in event with id0")]);
Obj-C
[Avo initAvoWithEnv:AVOEnvDev customDestination:[CustomDestination new] debugger:debugger];
[Avo appOpened];
Swift
Avo.initAvo(env: AvoEnv.dev, customDestination: CustomDestiation(), debugger: debugger)
Avo.appOpened()
Then after you call showDebugger in your activity the debugger view will appear with the App Opened event inside.
Avo (https://www.avo.app), [email protected]
IosAnalyticsDebugger is available under the MIT license. See the LICENSE file for more info.