hooks 0.20.4
hooks: ^0.20.4 copied to clipboard
A library that contains a Dart API for the JSON-based protocol for `hook/build.dart` and `hook/link.dart`.
example/README.md
Examples #
The examples in package:hooks show how to use package:hooks and
package:code_assets in build hooks to bundle native code with Dart and Flutter
applications.
| Example | Use Case | Used Features |
|---|---|---|
host_name |
Get the hostname. | - Accessing a system library with DynamicLoadingSystem and LookupInProcess.- OS-specific differences. |
mini_audio |
Play audio. | - C library built from source with package:native_toolchain_c.- Bundled with DynamicLoadingBundled. |
sqlite |
Database access. | - C library built from source with package:native_toolchain_c.- Bundled with DynamicLoadingBundled. |
sqlite_prebuilt |
Database access. | - Pre-built binary downloaded from the internet or available on host machine. - Bundled with DynamicLoadingBundled. |
stb_image |
Read image metadata. | - C library built from source with package:native_toolchain_c.- Bundled with DynamicLoadingBundled. |
The following examples showcase individual features of of package:hooks:
- build/ contains examples on how to use
hook/build.dartto build and bundle code assets, such as C libraries, into Dart applications. - link/ contains examples on how to treeshake unused assets from a Dart
application using the
hook/link.dartscript.