Skip to main content
Works everywhere. TypeScript, Zig, any language with C-FFI.

TypeScript Entrypoints

Voltaire provides three entrypoints with identical APIs for different performance profiles:
import { Address, Keccak256 } from '@tevm/voltaire'        // JS (default)
import { Address, Keccak256 } from '@tevm/voltaire/wasm'   // WASM
import { Address, Keccak256 } from '@tevm/voltaire/native' // Native FFI (Bun only)
All entrypoints implement the same VoltaireAPI interface - switch by changing the import path.
For detailed performance comparisons and choosing the right entrypoint, see Runtime Implementations.

Installation by Language

npm install @tevm/voltaire
# or: bun add @tevm/voltaire / pnpm add @tevm/voltaire / yarn add @tevm/voltaire
Then import from any entrypoint:
// JS (default) - works everywhere
import { Address, Keccak256 } from '@tevm/voltaire'

// WASM - for browser/edge crypto performance
import { Address, Keccak256 } from '@tevm/voltaire/wasm'

// Native - for Bun maximum performance
import { Address, Keccak256 } from '@tevm/voltaire/native'

First Class Support

TypeScript, Zig, and C - fully supported with complete APIs and documentation

C-FFI Support

Swift, Go, Python, Kotlin, and any language with foreign function interface support
C-FFI bindings require manual memory management. Always call corresponding _free functions to prevent leaks.

Consistent API

The Voltaire API is consistent across all languages.
import { Address } from '@tevm/voltaire'

const address = Address('0x742d35Cc6634C0532925a3b844Bc9e7595f51e3e')

Address.toChecksummed(address)
Address.toHex(address)
Address.isZero(address)
Address.equals(address, otherAddress)

// Also available as instance methods
address.toChecksummed()
address.toHex()
address.isZero()
address.equals(otherAddress)

Looking for Help

We’re looking for contributors to help build idiomatic wrappers for:
  • Go - Native bindings via cgo
  • Python - Bindings via ctypes/cffi
  • Swift - Fully implemented but lacking tests and complete documentation
  • Kotlin - Android/JVM bindings
Interested in contributing? Check out src/c_api.zig for the C-FFI interface and src/primitives.h for the generated C header. Join our Telegram or open an issue on GitHub.