implementing-jsc-classes-zig

Official

Zig-JSCore bindings for Bun.

Authorzhcndoc
Version1.0.0
Installs0

System Documentation

What problem does it solve?

This Skill provides a structured approach to implementing JavaScriptCore bindings for Bun by generating Zig-based bindings and .classes.ts interfaces, enabling seamless exposure of Zig APIs to JavaScript.

Core Features & Use Cases

  • Define interfaces in a .classes.ts file to describe classes, methods, and properties that bridge JS and Zig.
  • Implement the corresponding Zig code to back those interfaces, including constructors, methods, getters, and finalizers.
  • Generate and register the binding glue (C++/Zig interop) so the new API is accessible from Bun's JS runtime.
  • Use cases include adding native Bun APIs in Zig that expose high-performance functionality to JavaScript with type-safe bindings.

Quick Start

Create a .classes.ts that defines the target class; implement its Zig binding in a .zig file; run the binding generator/build to regenerate JS bindings; rebuild Bun to apply changes.

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: implementing-jsc-classes-zig
Download link: https://github.com/zhcndoc/bun/archive/main.zip#implementing-jsc-classes-zig

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.