Skip to content

Latest commit

 

History

History
31 lines (23 loc) · 1.1 KB

README.md

File metadata and controls

31 lines (23 loc) · 1.1 KB

XTP Plugin Bindgen

Warning: This is experimental and is still in the alpha phase. Changes will be made without warning. Please wait before you start writing new bindgens.

This repository houses the prototype for bingden for typescript plug-ins in XTP. It's based on the XTP Schema as the driving document. This document will be used to generate code and documentation for plug-in systems and is specifically tailored to Extism at the moment.

Building

An XTP gen template is distributed as a zip file with a plugin.wasm, config.yaml, and a templates directory of template files. To build this "bundle" run the bundle.sh command:

./bundle.sh

To test you can use the XTP CLI and plugin init. You just need to point it at a valid XTP Schema file:

xtp plugin init --schema-file ./tests/schemas/fruit.yaml --template ./bundle --path myplugin -y

Note: If you have not installed the xtp cli: curl https://static.dylibso.com/cli/install.sh | sudo sh