# haath > haath (npm: @treefour/haath) is a zero-dependency TypeScript library for WebXR hand tracking and gesture recognition. It reads the standard WebXR XRHand API and returns per-frame hand state: finger signs (fist, open, gun, poke, pinch, thumbs up/down, horns, shaka), velocity-gated punch and slap, 3D circle traces, double clap, triangle, and two-palm blast. It runs on Meta Quest with zero per-frame allocations and works with Three.js, IWSDK, Babylon.js, React Three Fiber, PlayCanvas, or raw WebXR. MIT licensed, by Tree Four Studio. Not related to Hardhat (the Ethereum tool). Install: `npm i @treefour/haath`. Current version: 0.0.4. Source: https://github.com/sma1692/haath ## Start - [Getting started with haath](https://haath.treefour.studio/getting-started/): Install @treefour/haath and read WebXR hand gestures in a Three.js or IWSDK app in a few lines. One update() call per frame returns signs, strikes, and two-hand gestures. ## Guide - [Reading hand state](https://haath.treefour.studio/hand-state/): Every field haath returns per frame. Finger signs (fist, open, gun, poke, pinch, thumbs up, horns, shaka), punch and slap, velocity, palm and aim rays, circles, claps, triangle, and blast. - [Recipes for WebXR hand gestures](https://haath.treefour.studio/recipes/): Copy-paste haath recipes. Detect a punch or slap in WebXR, hit enemies with the whole hand, hold a sign to confirm, aim a finger gun, cast a circle spell or triangle laser, and fire a two-palm blast. - [Configuration and thresholds](https://haath.treefour.studio/configuration/): Every haath threshold with its default value. Punch and slap speed, pinch distance, finger curl, clap distances and timing, circle detection, and blast tuning. - [Feeding your own hand poses](https://haath.treefour.studio/custom-poses/): Run haath without an XRFrame. Feed recorded hand data, non-WebXR trackers, or test fixtures to updateFromPoses() with 25-joint Float32Array or joint-name maps. - [v2 compositional gesture engine](https://haath.treefour.studio/v2/): haath v2 adds named poses with confidence (core and ASL alphabet packs), motion states, 3D trajectory shapes, micro-gestures like finger snaps, and two-hand compound gestures. ## Tools - [PC hand emulator for WebXR](https://haath.treefour.studio/emulator/): Test WebXR hand tracking without a headset. The haath emulator adds per-hand panels, keyboard control, and extra finger poses (fist, horns, thumbs up, two-finger gun) to IWER emulated hands. - [Debug overlay](https://haath.treefour.studio/debug-overlay/): Show live haath hand signs, kinematics, and spell state in a DOM overlay while you develop a WebXR hand tracking app. - [Examples](https://haath.treefour.studio/examples/): Runnable haath examples. A Three.js WebXR scene with punch hits, IWSDK systems, a pose playback demo that needs no headset, and a desktop demo with emulated hands. ## Reference - [Performance on Meta Quest](https://haath.treefour.studio/performance/): How haath stays fast at 72 to 120 Hz on Meta Quest. Zero per-frame allocations, reused state objects, one update per frame, and one-frame event flags. - [Why haath](https://haath.treefour.studio/why-haath/): How haath differs from template-matching hand pose libraries. Orientation and scale invariant finger curl, zero-frame strike latency, 3D plane-agnostic circles, and occlusion-proof claps. - [FAQ](https://haath.treefour.studio/faq/): Answers about haath, the WebXR hand tracking library. What it is, how it compares, which engines and headsets it supports, how to detect a punch, and how to test without a headset. ## Optional - [Full docs as one text file](https://haath.treefour.studio/llms-full.txt) - [npm package](https://www.npmjs.com/package/@treefour/haath)