Skip to content

Latest commit

 

History

History
54 lines (34 loc) · 1.69 KB

README.md

File metadata and controls

54 lines (34 loc) · 1.69 KB

Network Tools Flutter

pub package Dart codecov

Features

This package will add support for flutter features which is out of the scope of network_tools because of platform limitations.

Getting started

Usage

Add dependency in pubspec.yml, path_provider dependency is also needed

dependencies:
  flutter:
    sdk: flutter
    
  network_tools_flutter: ^1.0.4
  path_provider: ^2.1.2

And initialize the pacakge in the main function

 await configureNetworkToolsFlutter((await getApplicationDocumentsDirectory()).path);

From here please follow the documentation of network_tools as they are the same.

mDNS search

For mDNS search on android make sure your min Android API level is 21 and add the following permissiongs to the manifest file

<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.CHANGE_WIFI_MULTICAST_STATE" />

And for iOS add permissions to the Info.plist (replace service type with your own):

<key>NSLocalNetworkUsageDescription</key>
<string>Required to discover local network devices</string>
<key>NSBonjourServices</key>
<array>
    <string>_http._tcp</string>
</array>