Check out example codes for "logging exceptions into app insights from console application". It will help you in understanding the concepts better.
Code Example 1
// you may use different options to create configuration as shown later in this article TelemetryConfiguration configuration = TelemetryConfiguration.CreateDefault(); configuration.InstrumentationKey = " *your key* "; var telemetryClient = new TelemetryClient(configuration); telemetryClient.TrackTrace("Hello World!");
Learn ReactJs, React Native from akashmittal.com