Examples

The following complete examples use link hooks (hook/link.dart) and package:record_use to tree-shake native C libraries (LinkerOptions.treeshake):

ExampleDescriptionUsed Features
mini_audioPlay audio.- Tree-shaking C library built from source with package:native_toolchain_c based on recorded Dart calls.
- Link hook (hook/link.dart) with LinkerOptions.treeshake.
sqliteDatabase access.- Tree-shaking C library built from source with package:native_toolchain_c based on recorded Dart calls.
- Link hook (hook/link.dart) with LinkerOptions.treeshake.
stb_imageRead image metadata.- Tree-shaking C library built from source with package:native_toolchain_c based on recorded Dart calls.
- Link hook (hook/link.dart) with LinkerOptions.treeshake.