npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@robinbraemer/llrt

v0.1.2

Published

TypeScript-friendly Node bindings for AWS LLRT.

Readme

@robinbraemer/llrt

TypeScript-friendly Node bindings for AWS LLRT.

This package exposes LLRT as an embedded runtime through a napi-rs native addon. The public API is intentionally small while the proof of concept hardens.

npm install @robinbraemer/llrt

Usage

LlrtRuntime.callJson() runs an async JavaScript function in a fresh LLRT VM and returns a typed result envelope instead of throwing for guest failures:

import { LlrtRuntime } from "@robinbraemer/llrt";

const runtime = new LlrtRuntime({ memoryMB: 64, wallTimeMs: 1000 });

const result = await runtime.callJson<{ name: string }, { greeting: string }>(
  `async ({ input }) => ({ greeting: "Hello " + input.name })`,
  { name: "Ada" },
);

The boundary is JSON-safe:

  • the input value must serialize to JSON;
  • the guest return value is serialized back through JSON;
  • Host functions are explicit async functions passed per call through functions;
  • each call creates a fresh LLRT VM, so guest globals do not persist across calls.

Resource controls can be set on the runtime or per call:

const runtime = new LlrtRuntime({
  memoryMB: 64,
  wallTimeMs: 1000,
  maxStackBytes: 512 * 1024,
});

const result = await runtime.callJson(
  `async ({ input, host }) => host.echo(input)`,
  { ok: true },
  {
    memoryMB: 32,
    wallTimeMs: 500,
    functions: {
      echo: async (value) => value,
    },
  },
);

The package reports TIMEOUT, MEMORY_LIMIT, SERIALIZATION_ERROR, EVALUATION_ERROR, NATIVE_LOAD_ERROR, RUNTIME_DISPOSED, and UNSUPPORTED as typed error codes.

Runtime Support

Supported Node version:

  • Node.js 24

Supported native targets:

  • aarch64-apple-darwin
  • x86_64-apple-darwin
  • x86_64-unknown-linux-gnu
  • aarch64-unknown-linux-gnu

Unsupported runtimes:

  • Bun
  • Cloudflare Workers
  • browser environments

This package is a Node native addon and does not guarantee support in non-Node JavaScript runtimes.

Safety Boundaries

Guest code does not receive Node.js compatibility APIs by default. The runtime does not expose filesystem, process, require, or fetch unless a caller deliberately provides equivalent behavior through Host functions.

The isolation model is intentionally simple: every callJson() invocation uses a fresh LLRT VM with its own memory and wall-time limits. This is slower than a reused VM could be, but it avoids cross-call global state leaks and keeps resource limits scoped to one execution.

Native Packages

The main package ships JavaScript and TypeScript declarations. Platform-specific native binaries are published as optional packages generated by napi-rs:

  • @robinbraemer/llrt-darwin-arm64
  • @robinbraemer/llrt-darwin-x64
  • @robinbraemer/llrt-linux-x64-gnu
  • @robinbraemer/llrt-linux-arm64-gnu

For local development, build the native addon with:

pnpm --filter @robinbraemer/llrt run dev:native

Release preparation uses the napi-rs package layout:

pnpm --filter @robinbraemer/llrt run create:native-packages
pnpm --filter @robinbraemer/llrt run prepare:llrt-source
LLRT_TARGET=aarch64-apple-darwin pnpm --filter @robinbraemer/llrt run build:native:target
pnpm --filter @robinbraemer/llrt run collect:native-artifacts
pnpm --filter @robinbraemer/llrt run smoke:packed-install
pnpm --filter @robinbraemer/llrt run prepublish:native-packages:dry-run
pnpm --filter @robinbraemer/llrt run prepare:native-publish