intl_message 0.1.0

  • README.md
  • CHANGELOG.md
  • Installing
  • Versions
  • 68

intl_message

Build Status

Parses and formats ICU Message strings.

Usage

var msg = new IntlMessage("It is now {now, date, long}");

var str = msg.format({
  "now": new DateTime.now()
});

print(str);

msg = new IntlMessage({
  "nl": "Toon is geboren op {now, date, long}",
  "en": "Toon was born on {now, date, long}",
});

IntlMessage.withLocale("nl", () {
  var str = msg.format({
    "birthday": new DateTime(2008,8,16)
  });

  print(str);

});


Features and bugs

Please file feature requests and bugs at the issue tracker.

Changelog

0.1.0

  • Initial version

Use this package as a library

1. Depend on it

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


dependencies:
  intl_message: "^0.1.0"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

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

3. Import it

Now in your Dart code, you can use:


      import 'package:intl_message/intl_message.dart';
  
Version Uploaded Documentation Archive
0.1.0 Apr 1, 2018 Go to the documentation of intl_message 0.1.0 Download intl_message 0.1.0 archive

Analysis

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

  • Dart: 2.0.0-dev.63.0
  • pana: 0.11.3

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
37 / 100
Health:
Code health derived from static analysis. [more]
98 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100 / 100
Overall score:
Weighted score of the above. [more]
68
Learn more about scoring.

Platforms

Detected platforms: Flutter, web, other

No platform restriction found in primary library package:intl_message/intl_message.dart.

Suggestions

  • The description is too short.

    Add more detail about the package, what it does and what is its target use case. Try to write at least 60 characters.

  • Package is pre-v1 release.

    While there is nothing inherently wrong with versions of 0.*.*, it usually means that the author is still experimenting with the general direction API.

  • Fix analysis and formatting issues.

    Analysis or formatting checks reported 10 hints.

    Run dartfmt to format lib/intl_message.dart.

    Run dartfmt to format lib/src/formatted.dart.

    Similar analysis of the following files failed:

    • lib/src/intl/ordinal_rules.dart (hint)
    • lib/src/message.dart (hint)
    • lib/src/multilanguage.dart (hint)
    • lib/src/parser.dart (hint)
    • lib/src/select.dart (hint)
  • Maintain an example.

    Create a short demo in the example/ directory to show how to use this package. Common file name patterns include: main.dart, example.dart or you could also use intl_message.dart.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.20.1 <2.0.0
intl ^0.15.2 0.15.6
petitparser ^1.6.1 1.7.6
Transitive dependencies
matcher 0.12.3
path 1.6.1
stack_trace 1.9.2
Dev dependencies
test ^0.12.0