niddler_dart 0.6.0 copy "niddler_dart: ^0.6.0" to clipboard
niddler_dart: ^0.6.0 copied to clipboard

outdated

Niddler network inspector for dart and flutter! Use the niddler IntelliJ and Android Studio plugin to debug your network requests during development.

Niddler network inspector for dart and flutter

latestVersion

Usage #

A simple usage example:

For a more complete example, see example/main.dart.

import 'package:niddler_dart/niddler_dart.dart';
import 'package:stack_trace/stack_trace.dart';

main() async {
  await Chain.capture(() async { //For better flutter stack traces, wrap main code in this Chain.capture from package stack_trace
    final niddlerBuilder = NiddlerBuilder()
        ..bundleId = 'com.test.test'
        ..serverInfo = NiddlerServerInfo('Some descriptive name', 'Some description')
        ..includeStackTrace = true //Capture request stack traces. Wrap all content inside main with `Chain.capture`
        ..port = 0; //0 to have niddler pick it's own port. Automatic discovery will make this visible
  
      final niddler = niddlerBuilder.build();
      await niddler.start();
      niddler.install();
    
      //Make http requests ...
    
      await niddler.stop();
  });
}

Request site stack traces #

Since 0.6.0, niddler supports capturing stack traces at request site across async boundaries. This can have a (very) small performance impact.

To enable, configure niddler to include stack traces by setting includeStackTrace = true in the builder, optionally configuring which stack frames to throw out via sanitizer = implementation of StackTraceSanitizer (defaults to a reasonable sanitizer for dart/flutter/dio).

To capture stack traces across async blocks, wrap ALL code inside your main with Chain.capture from package:stack_trace

Viewing stack traces for dart code is supported in the intellij plugin since version 2.5.0

Features and bugs #

Please file feature requests and bugs at the issue tracker.

10
likes
0
pub points
65%
popularity

Publisher

verified publisherchimerapps.com

Niddler network inspector for dart and flutter! Use the niddler IntelliJ and Android Studio plugin to debug your network requests during development.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

pointycastle, stack_trace, synchronized, uuid

More

Packages that depend on niddler_dart