flutterzoop 0.0.5

  • Readme
  • Changelog
  • Example
  • Installing
  • 56

flutterzoop #

A Flutter Zoop plugin.

Getting Started #

This project is a starting point for a Flutter plug-in package, a specialized package that includes platform-specific implementation code for Android and/or iOS.

For help getting started with Flutter, view our online documentation, which offers tutorials, samples, guidance on mobile development, and a full API reference.

0.0.1 #

  • TODO: Describe initial release.

0.0.3 #

  • Fix update devices listener.

0.0.4 #

  • Added abort charge.

0.0.4 #

  • Fix: Reset state before charge.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:flutterzoop/flutterzoop.dart';

import 'bluetoothOffScreen.dart';
import 'findDevice.dart';

void main() {
  runApp(FlutterZoopApp());
}

class FlutterZoopApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      color: Colors.lightBlue,
      home: StreamBuilder<BluetoothState>(
          stream: FlutterZoop.instance.state,
          initialData: BluetoothState.unknown,
          builder: (c, snapshot) {
            final state = snapshot.data;
            if (state == BluetoothState.on) {
              return FindDevicesScreen();
            }
            return BluetoothOffScreen(state: state);
          }),
    );
  }
}

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  flutterzoop: ^0.0.5

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter pub get

Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:flutterzoop/flutterzoop.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
32
Health:
Code health derived from static analysis. [more]
86
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
70
Overall:
Weighted score of the above. [more]
56
Learn more about scoring.

We analyzed this package on Jul 14, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.8.4
  • pana: 0.13.15
  • Flutter: 1.17.5

Analysis suggestions

Package does not support Flutter platform Linux

Because:

  • package:flutterzoop/flutterzoop.dart that declares support for platforms: Android

Package does not support Flutter platform Web

Because:

  • package:flutterzoop/flutterzoop.dart that declares support for platforms: Android

Package does not support Flutter platform Windows

Because:

  • package:flutterzoop/flutterzoop.dart that declares support for platforms: Android

Package does not support Flutter platform iOS

Because:

  • package:flutterzoop/flutterzoop.dart that declares support for platforms: Android

Package does not support Flutter platform macOS

Because:

  • package:flutterzoop/flutterzoop.dart that declares support for platforms: Android

Package not compatible with SDK dart

Because:

  • flutterzoop that is a package requiring null.

Health suggestions

Fix lib/gen/flutterzoop.pb.dart. (-12.66 points)

Analysis of lib/gen/flutterzoop.pb.dart reported 27 hints, including:

line 26 col 23: Name non-constant identifiers using lowerCamelCase.

line 69 col 23: Name non-constant identifiers using lowerCamelCase.

line 121 col 23: Name non-constant identifiers using lowerCamelCase.

line 200 col 23: Name non-constant identifiers using lowerCamelCase.

line 259 col 23: Name non-constant identifiers using lowerCamelCase.

Fix lib/gen/flutterzoop.pbenum.dart. (-1.99 points)

Analysis of lib/gen/flutterzoop.pbenum.dart reported 4 hints:

line 5 col 7: Name types using UpperCamelCase.

line 36 col 7: Name types using UpperCamelCase.

line 58 col 7: Name types using UpperCamelCase.

line 79 col 7: Name types using UpperCamelCase.

Format lib/src/zoop_error_message.dart.

Run flutter format to format lib/src/zoop_error_message.dart.

Maintenance suggestions

The package description is too short. (-20 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.7.0 <3.0.0
convert ^2.1.1 2.1.1
flutter 0.0.0
intl ^0.16.1 0.16.1
protobuf ^1.0.1 1.0.1
rxdart ^0.24.0 0.24.1
Transitive dependencies
charcode 1.1.3
collection 1.14.12 1.14.13
fixnum 0.10.11
meta 1.1.8 1.2.2
path 1.7.0
sky_engine 0.0.99
typed_data 1.1.6 1.2.0
vector_math 2.0.8 2.1.0-nullsafety
Dev dependencies
flutter_test