credits_builder 0.0.1 copy "credits_builder: ^0.0.1" to clipboard
credits_builder: ^0.0.1 copied to clipboard

A Flutter package for build a credits page of your dependencies.

Credits builder #

A simple package to generate a credit page of your dependencies. The best way to thank and appreciate the work of third party libraries.

Configuration #

Setup the dependency:

dependencies:
  credits_builder: ^0.0.1                 # android   ios   linux   macos   web   windows

credits_builder:
  outputFile: "assets/dependencies.json"  # default value

Usage #

Generate the dependencies file #

By running this command you will create/update your dependencies file in the assets folder (assets/dependencies.json):

dart run credits_builder:start

Runtime side #

Basic way to retrieve dependencies at runtime:

Future<List<Dependency>> getDependencies(BuildContext context) =>
      CreditsBuilder().config().get(context);

If you defined a dependency file name different from the default you can retrieve the information like this:

 Future<List<Dependency>> getDependencies(BuildContext context) =>
    CreditsBuilder()
        .config(
          path: 'assets/other_file_name.json',
        )
        .get(context);

If you want to preprocess the file information before using it (for example to deobfuscate the file with Stringcare) you can do it like this:

 Future<List<Dependency>> getDependencies(BuildContext context) =>
    CreditsBuilder()
        .config(
          process: (data) async => Stringcare().revealData(data) ?? data,
        )
        .get(context);
0
likes
0
pub points
15%
popularity

Publisher

verified publisherlandamessenger.com

A Flutter package for build a credits page of your dependencies.

Homepage

License

unknown (LICENSE)

Dependencies

dio, flutter, flutter_localizations, http, pub_api_client, yaml, yaml_writer

More

Packages that depend on credits_builder