nekos_best

Last updated:

0 purchases

nekos_best Image
nekos_best Images
Add to Cart

Description:

nekos best

Nekos.Best Dart #


A minimal Dart package for interacting with Nekos.best api.
Getting started #
Add the package to your project's pubspec.yaml file. You can use the dart cli
$ dart pub add nekos_best
copied to clipboard
Usage #
Import the package in your dart file and use the methods
import 'package:nekos_best/nekos_best.dart' as nb;

var res = nb.fetch(endpoint: 'neko');
copied to clipboard
Classes #
Detailed documentation can be found in the Package API Reference. There is also examples on general usage of the package in the Official Nekos.Best docs.
The package exports a Client class and a fetch method. The fetch method uses the Client classes Client.fetch method internally. The client class has other two methods, a search method and a fetchFile method.
All possible usages are listed in details in the example/ directory.
Response #
There are two classes: NBResponse & NBBufferResponse. They have the following fields. Refer to the officials nekos.best docs for more info.
class NBResponse {
final String url;
final String? artist_href;
final String? artist_name;
final String? source_url;
final String? anime_name;
}

class NBBufferResponse {
final List<int> data;
final String? artist_href;
final String? artist_name;
final String? source_url;
final String? anime_name;
}
copied to clipboard
You can access the fields with dot notation i.e.
var neko_url = neko.url; // neko is an instance of NBResponse
copied to clipboard
See example/structs_example.dart for more.
Author #
nekos_best_dart © Yakiyo. Authored and maintained by Yakiyo.
Released under MIT License

License:

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.