hooks 0.20.5 copy "hooks: ^0.20.5" to clipboard
hooks: ^0.20.5 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.dart to 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.dart script.
16
likes
160
points
2.16M
downloads

Publisher

verified publisherlabs.dart.dev

Weekly Downloads

A library that contains a Dart API for the JSON-based protocol for `hook/build.dart` and `hook/link.dart`.

Repository (GitHub)
View/report issues
Contributing

Topics

#assets #ffi #hooks #interop #native-assets

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

collection, crypto, logging, meta, pub_semver, yaml

More

Packages that depend on hooks