Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Changing generated Typescript or C++ bindings templates

The central workings of a uniffi-bingen are its templates.

uniffi-bindgen-react-native templates are in the following directories:

Templates are written for Rinja templating library.

The WASM crate is generated with quote, in the gen_rust module.

There is a small-ish runtime for both languages:

This is intended to allow developers from outside the project to contribute more easily.

Making a change to the templates should be accompanied by an additional test, either in an existing test fixture, or a new one.

Running the tests can be done with:

./scripts/run-tests.sh

An individual test can be run:

./scripts/run-tests.sh -f $fixtureName