Abstract
METACALL is a library that allows calling functions, methods or procedures between programming languages. With METACALL you can transparently execute code from / to any programming language, for example, call TypeScript code from Rust.
Install
MetaCall is a C plugin based library. This crate wraps the C library into Rust, so in order to make it work, you should install MetaCall binaries first (click here for installing it on other platforms):
|
Linking
If your project uses MetaCall in a folder that is not in the system path, we encourage to use metacall-sys
crate as a build-dependecy
. By this way you will be able to locate and link MetaCall directly in your build system. For example:
Cargo.toml
:
[]
= "0.1.2"
build.rs
:
Example
sum.ts
export : number
main.rs
use ;