cuba_weather_insmet_dart 0.2.2

  • Readme
  • Changelog
  • Example
  • Installing
  • 44

Cuba Weather InsMet Dart #

License: MIT Pub Version GitHub Workflow Status

Application programming interface of the Cuba Weather project for www.insmet.cu implemented in Dart.

  • To see how to install the package, follow this link.

  • To see examples of use, follow this link.

  • To see the package page on pub.dev, follow this link.

  • To see the changelog, follow this link.

Cuba Weather InsMet Dart Changelog #

[0.2.2] - January 26, 2020 #

  • Add state

[0.2.1] - January 26, 2020 #

  • Update dependencies

[0.2.0] - January 26, 2020 #

  • Add the datetime information
  • Add the today's weather forecast information
  • Add the drought status information

[0.1.1] - January 25, 2020 #

  • Update cuba_weather_municipality_dart package to v0.1.2
  • Fix descriptions

[0.1.0] - January 25, 2020 #

  • Initial implementation

example/example.dart

import 'dart:io';

import 'package:cuba_weather_insmet_dart/cuba_weather_insmet_dart.dart';

void main() {
  print('Insert municipality:');
  var input = stdin.readLineSync();
  var cubaWeatherInsMet = CubaWeatherInsMet();
  cubaWeatherInsMet.get(input).then((weather) {
    print(weather);
  });
}

Use this package as a library

1. Depend on it

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


dependencies:
  cuba_weather_insmet_dart: ^0.2.2

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter pub get

Alternatively, your editor might support pub get or 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:cuba_weather_insmet_dart/cuba_weather_insmet_dart.dart';
  
Popularity:
Describes how popular the package is relative to other packages. [more]
0
Health:
Code health derived from static analysis. [more]
99
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
70
Overall:
Weighted score of the above. [more]
44
Learn more about scoring.

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

  • Dart: 2.8.2
  • pana: 0.13.8-dev

Health suggestions

Fix lib/src/models/weather_model.dart. (-1 points)

Analysis of lib/src/models/weather_model.dart reported 2 hints:

line 68 col 28: Unnecessary new keyword.

line 96 col 28: Unnecessary new keyword.

Maintenance issues and suggestions

Homepage URL doesn't exist. (-20 points)

At the time of the analysis the homepage field https://github.com/cuba-weather/cuba-weather-insmet-dart was unreachable.

Support latest dependencies. (-10 points)

The version constraint in pubspec.yaml does not support the latest published versions for 1 dependency (xml).

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.1.0 <3.0.0
cuba_weather_municipality_dart ^0.1.3 0.1.3
html ^0.14.0+3 0.14.0+3
http ^0.12.0 0.12.1
xml ^3.7.0 3.7.0 4.2.0
Transitive dependencies
charcode 1.1.3
collection 1.14.12
convert 2.1.1
csslib 0.16.1
http_parser 3.1.4
meta 1.1.8
path 1.7.0
pedantic 1.9.0
petitparser 3.0.4
source_span 1.7.0
string_scanner 1.0.5
term_glyph 1.1.0
typed_data 1.1.6