Skip to content

Commands

m4bwav edited this page Nov 19, 2026 · 3 revisions

Every output on this page is filled from the threewright 1.6.0 tag-archive verification on Windows, with tw standing for node <plugin>/scripts/tw.mjs. Paths of the scratch folder are shown as <work>, the local server's port as <port>, and numbers that change from run to run with timing as <n>, <h>, <s> and the like. The verification program is ai-docs/notes/2026-11-18-wiki-verify.py in the repository.

Add --json to any command for machine-readable output.

The command list

tw --help
threewright CLI (tw)  usage: node scripts/tw.mjs <command> [options]

Verify a page (file, folder with index.html, or URL); text first, images on request:
  check <page>          errors, warnings, failed requests, renderer and scene summary, runtime warnings,
                        pixel evidence (coverage, bounds, brightness of what the canvas shows)
  scene <page>          compact scene-graph tree (--depth 6 --max 80)
  check <page> --eval "<js>"   also print the value of an expression after the page settles
                        (renderer, scene and camera are bound to the main ones tw observed)
  check <page> --strict        also fail on any console warning (three's own deprecation warnings always fail)
  check <page> --save run.json ; check <page> --against run.json   what changed since a saved run:
                        renderer and scene counts, object types, new or gone problems, changed frame region
  check <page> --cycles 5 [--cycle "<js>"]   run window.__tw.cycle() (or the js) N times and fail on
                        steady growth of geometries, textures or programs (a leak)
  check <page> --shot a.png --sheet b.png --tree   extra outputs from the same browser launch
                        (pages defining render_game_to_text() get its text printed as game:)
  shaders <page> [--dump dir]   WebGL programs, their materials and link status; a failing
                        shader's error lines with source context; --dump writes .vert/.frag files
  perf <page> [--seconds 5] [--cpu-throttle 4]   frame time p50/p95/p99/max, frames over 33 ms,
                        draw calls and triangles per frame, geometry, texture and heap growth
                        --fly "<js using u>" moves the camera each frame (u runs 0 to 1 over the run);
                        bare --fly calls the page's window.flyThrough(u); --target-ms 16.7 fails when p95 is over
  shot <page> --out f.png [--canvas] [--alpha]   one screenshot; prints its token cost (.jpg or .webp
                        write that format, --quality 82, e.g. for a poster image)
                        (shot and sheet take --eval "<js>" to set a state first, e.g. scrollTo(0, 2000))
  sheet <page> --out f.png [--views current,front,right,top]   several angles in one image
  sheet <page> --sweep "find('knot').material.roughness=0,0.5,1"   one tile per value, current view
                        (shot and sheet take --labels: name tags on objects, legend printed as text)
  video <page> --out f.mp4|.webm|.gif|.mov --seconds 5 --fps 30 [--alpha] [--frames-dir d]
                        deterministic capture via ffmpeg (alpha: .webm or .mov, page cleared transparent;
                        --capture canvas reads the canvas alone, without HTML overlays; a page's
                        __tw.renderFrame(i, fps) or advanceTime(ms) drives the frames when defined)
  --actions "key KeyW 500; click 480,270; drag 100,100 300,120; wheel 480,270 -120; type hi; wait 500"
                        input sent before check, shot, sheet or video measures or captures
      page options: --size 960x540 --dpr 1 --gl auto|gpu|swiftshader --webgpu --wait 1000 --root dir
                    --reduced-motion --color-scheme light|dark --timeout 60000 --headed
                    --cdn auto|offline|net   pinned jsDelivr/unpkg files come from node_modules or the
                                             npm cache (auto: CDN when absent, npm if the CDN fails)
Static tools (no browser):
  diff <a.png> <b.png> [--threshold 0.1] [--max 0.001] [--out d.png]   pixel comparison, PASS/FAIL
  lint <files|dirs> [--target r186] [--md] [--strict]   stale or risky three.js API use, with the
                        release that changed it and the fix (rules: kb/rules/lint-rules.json)
  look <render.png> <reference.png> [--min 70] [--sheet s.png] [--fit look.cube]   colour-grade match
                        0-100 from OKLab statistics (brightness, tint, chroma, hue, contrast, detail);
                        camera need not match; --fit writes a .cube LUT for LUTPass and re-scores
  glb <file.glb|.gltf> [--strict]   model report: size, draw calls, triangles, textures in px,
                        extensions and their decoders, animations, world bounds, web-budget warnings
                        --strict exits 1 on any warning
  kb search <words>     find knowledge-base entries (top 8, one line each)
  kb show <slug> [--section name ...]   print an entry or only some sections
  kb list [--kind topic|scenario|library|recipe|rule] ; kb index ; kb validate [--strict]
  kb note <slug> "<text>"   add a dated note to an entry
  new <template> <dir> [--force] [--no-vendor]   copy a verified starter (tw templates lists them);
                        site templates vendor their CDN modules unless --no-vendor
  vendor <dir|page.html> [--offline] [--dry-run]   copy the pinned CDN modules the page imports
                        (and their own imports) into vendor/ and point the import map at them
  templates             list starters and where each was verified
  versions [--check]    latest npm versions vs the knowledge base and templates
  deprecations [--src node_modules/three] [--all]   @deprecated markers no lint rule covers yet
  doctor                node, chrome, ffmpeg, npm, CDN reach, WebGL and WebGPU in headless Chrome
Global: --json for machine output. Image costs use Claude's 28 px patches (TW_IMAGE_TIER=standard
for models before Claude 4.7).

Verify a page

A page is a file, a folder with an index.html, or a URL. Local pages are served from 127.0.0.1 (Chrome blocks module imports from file://), and a local path may carry a query string or hash (tw check "page/?model=x.glb").

check

tw check site/

On the html-importmap starter (tw new html-importmap site) it prints:

page: http://127.0.0.1:<port>/index.html
three: r186 · scenes 2 · render calls <n>
renderer: WebGLRenderer canvas 960x540 dpr 1 · draw calls 3 · tris 15424 · geometries 14 · textures 5 · programs 5 · output srgb · toneMapping ACESFilmic · shadows PCF
gpu: ANGLE (NVIDIA, NVIDIA GeForce RTX 5060 Ti (0x00002D04) Direct3D11 vs_5_0 ps_5_0, D3D11)
cdn: 4 file(s) served locally (three@0.186.1 from cache)
scene: Mesh 2, Scene 1, DirectionalLight 1
  meshes 2 · lights 1 · verts 4091 · tris 7744 · materials 2 · textures 0 · environment true · background #1b1d22
bounds: center 0,0.92,0 size 6,2.27,6
camera: PerspectiveCamera pos 3,2.2,4 fov 45 near 0.1 far 100 aspect 1.78
pixels: 46% differ from the background #1b1d22 · bbox x 0.06-0.94 y 0.21-1 · mean luma 0.45 · <n> colours
result: OK (no exceptions, errors, failed requests, three deprecations or scene warnings)

Line by line: three is the release tw detected, with how many scenes and render() calls it saw. renderer gives the main renderer's numbers for the last frame. cdn says the pinned jsDelivr or unpkg files were served from node_modules or the tw cache. scene and bounds describe the main scene: the one rendered in most frames, never an environment scene when anything else exists. pixels is what the canvas shows, measured against its background colour. result is OK or PROBLEMS FOUND. The scene count is 2 here because the starter bakes a RoomEnvironment. Exit code 0 on OK, 1 otherwise. What makes it fail is on Errors and edge cases.

Page options shared by the browser commands: --size 960x540 --dpr 1 --gl auto|gpu|swiftshader --webgpu --wait 1000 --root dir --reduced-motion --color-scheme light|dark --timeout 60000 --headed --cdn auto|offline|net.

check --eval

--eval prints the value of one expression after the page settles. renderer, scene and camera are bound to the main ones tw observed, so this works on pages that keep them in module scope:

tw check site/ --eval "renderer.info.render.calls > 0"

The output is the same as above with one line added before result:

eval: true
tw check site/ --eval "scene.getObjectByName('knot').material.color.getHexString()"
eval: "3fa7ff"

The expression is one expression: join steps with commas, "(__tw.setProgress(1), hide())"; a ; is a syntax error.

check --save and --against

tw check site/ --save before.json
tw check site/ --against before.json

The first run adds saved before.json; the second compares renderer and scene counts, object types, problems and the changed frame region:

against before.json (<time>): 1 change(s)
  pixels: 5.2% of the frame changed · region x 0.38-0.63 y 0.19-0.59 · mean luma 0.45 -> 0.45

The starter animates, so two runs of the unchanged page can differ by a few percent of the frame, as here (1.6.0 run). A static page prints no changes.

Other check options: --strict also fails on any console warning (three's own deprecation warnings always fail), --cycles 5 [--cycle "<js>"] runs window.__tw.cycle() or the expression N times and fails on steady growth of geometries, textures or programs, --shot a.png --sheet b.png --tree makes extra outputs in the same browser launch, and --actions "key KeyW 500; click 480,270; drag 100,100 300,120; wheel 480,270 -120; type hi; wait 500" sends input first. A page that defines render_game_to_text() gets its text printed as game:.

scene

tw scene site/
Scene
  DirectionalLight · pos 4,6,3 · intensity 2 #ffffff shadow
  Mesh "knot" · pos 0,0.9,0 · TorusKnotGeometry v4025 · MeshStandardMaterial #3fa7ff
  Mesh "ground" · CircleGeometry v66 · MeshStandardMaterial #3a3d45

--depth 6 --max 80 limit the tree; long runs of similar siblings are collapsed.

shot and sheet

tw shot site/ --out shot.png
wrote shot.png (960x540, 700 image tokens)

It then prints the same pixels: line as check. --canvas captures the canvas alone, --alpha keeps transparency, .jpg or .webp write that format (--quality 82) for a poster, and --eval "<js>" sets a state first (scrollTo(0, 2000)).

tw sheet site/ --out sheet.png
wrote sheet.png (960x540, 700 image tokens)

A sheet puts several angles (--views current,front,right,top) in one image. --sweep "find('knot').material.roughness=0,0.5,1" makes one tile per value from the current view and puts the old value back afterwards; --labels (on shot too) draws name tags on objects and prints the legend as text.

diff

tw diff shot.png shot.png
0 pixel(s) differ (0.000%, budget 0.100%) · largest channel change 0 · PASS

--threshold 0.1 is the per-channel tolerance, --max 0.001 the share of pixels allowed to differ, --out d.png writes the difference. Exit code 1 on FAIL.

perf

tw perf site/ --seconds 2
perf 2s (headless, uncalibrated): <n> frames · <fps> fps
frame ms: <timings>
per frame: draw calls 3 · triangles 15424
memory: geometries 14 -> 14 · textures 5 -> 5 · JS heap <mb> -> <mb>

The frame times are left out here because they change every run. Headless Chrome ran at a 60 fps vsync cap on the test machine, so fps says little: read p95, p99 and max. --cpu-throttle 4 slows the CPU.

video

tw video site/ --out turn.mp4 --seconds 1 --fps 10
wrote <work>\turn.mp4 · 10 frames at 10 fps (1s) · 32 KB · driver virtual clock · took <s>

Formats: .mp4, .webm, .gif, .mov; --alpha needs .webm or .mov. The driver is the virtual clock unless the page defines __tw.renderFrame(i, fps) or advanceTime(ms); --capture canvas reads the canvas without HTML overlays and --frames-dir d writes the frames. Needs ffmpeg.

shaders

tw shaders bad-shader/

On the repository's tests/fixtures/pages/bad-shader page, whose fragment shader uses an undeclared glowColour:

programs 2 (WebGL) · 1 FAILED
  #0 MeshNormalMaterial "ok" · linked · used by MeshNormalMaterial "ok" · vertex 514 lines, fragment 286 lines
  #1 ShaderMaterial "glow" · FAILED · used by ShaderMaterial "glow" · vertex 69 lines, fragment 57 lines
FAILED #1 ShaderMaterial "glow":
  program: Fragment shader is not compiled.
  fragment:
    line 57: 'glowColour' : undeclared identifier; 'constructor' : not enough data provided for construction
        54 | 	return dot( weights, rgb );
        55 | }
        56 | 
    >   57 | void main() { gl_FragColor = vec4(glowColour, 1.0); }
[exit 1]

--dump dir writes each program's .vert and .frag. It lists WebGL programs only; WebGPU WGSL errors show up in tw check.

Static tools

lint

tw lint old/

On an r150-era page (old/index.html):

<!doctype html>
<script src="https://unpkg.com/three@0.150.0/build/three.min.js"></script>
<script src="https://unpkg.com/three@0.150.0/examples/js/controls/OrbitControls.js"></script>
<script>
  const renderer = new THREE.WebGLRenderer();
  renderer.physicallyCorrectLights = true;
  const controls = new THREE.OrbitControls(camera, renderer.domElement);
  const box = new THREE.BoxBufferGeometry(1, 1, 1);
</script>

it prints:

three r150 (pinned URL) · 1 file(s)
old\index.html:2:46 warn umd-build: the UMD builds build/three.js and build/three.min.js were deprecated in r150 and removed in r161 (the cdnjs package "three.js" ships the same UMD files under a different path)
    fix: load the ES module build through an import map ("three": ".../build/three.module.js") or a bundler
old\index.html:3:46 error examples-js: examples/js (global-script addons) was removed in r148
    fix: import addons as modules from three/addons/... (examples/jsm)
old\index.html:6:12 warn physically-correct-lights: physicallyCorrectLights is gone (renamed useLegacyLights in r150); physically based light units are the only mode now
    fix: delete the line and retune light intensities (candela, lux) if the scene looks too dark
old\index.html:7:20 error global-three-addon: addons are not on the THREE namespace; the global-script versions were removed in r148
    fix: import { OrbitControls } from 'three/addons/controls/OrbitControls.js' and call new OrbitControls(...)
old\index.html:8:25 warn buffer-geometry-aliases: the *BufferGeometry aliases (BoxBufferGeometry and so on) were deprecated in r144 and removed in r154
    fix: use BoxGeometry, SphereGeometry and so on (they are BufferGeometry)
2 error(s), 3 warning(s)
[exit 1]

Each finding names the rule, the release that changed the API and the fix. The first line is the release lint assumed: here read from the pinned URL; otherwise --target r186. Exit code 1 when there is an error; --strict also fails on warnings. --md also lints the code fences of markdown files found in a folder; a markdown file named on the command line is always linted.

Rules with severity info are notes. The 0.6.6 note composer-without-aa fires on an EffectComposer with no multisampled target and no AA pass (post/bloom.js):

import { EffectComposer } from 'three/addons/postprocessing/EffectComposer.js';
import { RenderPass } from 'three/addons/postprocessing/RenderPass.js';
import { OutputPass } from 'three/addons/postprocessing/OutputPass.js';

const composer = new EffectComposer(renderer);
composer.addPass(new RenderPass(scene, camera));
composer.addPass(new OutputPass());
three r186 (latest known (r186)) · 1 file(s)
post\bloom.js:5:18 info composer-without-aa: antialias: true only multisamples the canvas; three.js's EffectComposer renders into its own render targets, created without samples, so edges come out aliased (and alphaToCoverage does nothing) unless the composer gets a multisampled target or an AA pass
    fix: new EffectComposer(renderer, new WebGLRenderTarget(w, h, { type: HalfFloatType, samples: 4 })), or add SMAAPass or FXAAPass before OutputPass
0 error(s), 0 warning(s), 1 note(s)
[exit 0]

A note does not change the exit code. Give the composer a multisampled target and the note goes:

import { WebGLRenderTarget, HalfFloatType } from 'three';

const target = new WebGLRenderTarget(innerWidth, innerHeight, { type: HalfFloatType, samples: 4 });
const composer = new EffectComposer(renderer, target);
three r186 (latest known (r186)) · 1 file(s)
0 error(s), 0 warning(s)
[exit 0]

The 0.6.5 note typed-buffer-attribute-copies (wave/wave.js):

function makeWave(count) {
  const positions = new Float32Array(count * 3);
  const geometry = new BufferGeometry();
  geometry.setAttribute('position', new Float32BufferAttribute(positions, 3));
  for (let i = 0; i < count; i++) positions[i * 3 + 1] = Math.sin(i);
  return geometry;
}
three r186 (latest known (r186)) · 1 file(s)
wave\wave.js:6:37 info typed-buffer-attribute-copies: this typed BufferAttribute was given an array that is written again later, but the typed subclasses copy the array they are given (new Float32Array(array)), so those writes never reach the GPU, silently
    fix: for data you update later, write into the attribute's own array (const a = attr.array) or use new BufferAttribute(typedArray, itemSize), which keeps it
0 error(s), 0 warning(s), 1 note(s)
[exit 0]

glb

tw glb forest.glb

On a model with one tree mesh placed by 150 plain nodes:

forest.glb · 8 KB (JSON 8 KB, binary 1 KB) · glTF 2.0 · wiki-verify
scenes 1 · nodes 150 · meshes 1 (1 primitives, 150 draw calls) · vertices 450 · triangles 150
materials 1 (opaque 1) · textures 0 · images 0
bounds: size 29 x 2 x 18 · center 14.5, 1, 9
warnings (1):
  149 nodes repeat a mesh another node already draws: instance them (gltf-transform instance, gltfpack -mi, or Blender's glTF export with GPU instances)
[exit 0]

From 0.6.6, draw calls are counted per node that draws a mesh, and 50 or more nodes that repeat a mesh get the warning. The same 150 trees as one EXT_mesh_gpu_instancing node:

tw glb forest-instanced.glb
forest-instanced.glb · 3 KB (JSON 1 KB, binary 2 KB) · glTF 2.0 · wiki-verify
extensions: EXT_mesh_gpu_instancing
scenes 1 · nodes 1 · meshes 1 (1 primitives, 1 draw calls) · vertices 450 · triangles 150
materials 1 (opaque 1) · textures 0 · images 0
bounds: size 1 x 2 x 0 · center 0.5, 1, 0
[exit 0]

A double-sided card with alphaMode BLEND and a 1000 x 750 texture gets the two other 0.6.6 warnings:

tw glb cards.glb
cards.glb · 4 KB (JSON 1 KB, binary 3 KB) · glTF 2.0 · wiki-verify
scenes 1 · nodes 1 · meshes 1 (1 primitives, 1 draw calls) · vertices 3 · triangles 1
materials 1 (blend 1, double-sided 1) · textures 1 · images 1 (png 1; 3 KB; largest 1000 px)
bounds: size 1 x 2 x 0 · center 0.5, 1, 0
warnings (2):
  1 material(s) are alphaMode BLEND and double-sided: if they are leaf, grass, fence or hair cards, use MASK (alphaTest, or alphaToCoverage with MSAA); blended cards sort per object and swap order as the camera moves
  1 texture(s) with a side that is not a multiple of 4: KTX2 encoding needs multiples of 4, and powers of two (512, 1024, 2048) suit mipmaps and compression best
[exit 0]

The exit code is 0 with warnings. --strict makes it 1 when there is any warning (tw --help does not list --strict for glb; it is in scripts/lib/glb.mjs):

tw glb cards.glb --strict
cards.glb · 4 KB (JSON 1 KB, binary 3 KB) · glTF 2.0 · wiki-verify
scenes 1 · nodes 1 · meshes 1 (1 primitives, 1 draw calls) · vertices 3 · triangles 1
materials 1 (blend 1, double-sided 1) · textures 1 · images 1 (png 1; 3 KB; largest 1000 px)
bounds: size 1 x 2 x 0 · center 0.5, 1, 0
warnings (2):
  1 material(s) are alphaMode BLEND and double-sided: if they are leaf, grass, fence or hair cards, use MASK (alphaTest, or alphaToCoverage with MSAA); blended cards sort per object and swap order as the camera moves
  1 texture(s) with a side that is not a multiple of 4: KTX2 encoding needs multiples of 4, and powers of two (512, 1024, 2048) suit mipmaps and compression best
[exit 1]

--json gives the full report:

tw glb forest-instanced.glb --json
{
  "file": "forest-instanced.glb",
  "bytes": 2792,
  "jsonBytes": 892,
  "binBytes": 1872,
  "glb": true,
  "version": "2.0",
  "generator": "wiki-verify",
  "extensionsUsed": [
    "EXT_mesh_gpu_instancing"
  ],
  "extensionsRequired": [],
  "needs": [],
  "scenes": 1,
  "nodes": 1,
  "meshes": 1,
  "primitives": 1,
  "drawCalls": 1,
  "vertices": 450,
  "triangles": 150,
  "geometryBytes": 72,
  "materials": 1,
  "alphaModes": {
    "OPAQUE": 1
  },
  "doubleSided": 0,
  "unlit": 0,
  "textures": 0,
  "images": 0,
  "imageBytes": 0,
  "imageTypes": {},
  "largestImage": null,
  "animations": [],
  "skins": [],
  "morphTargets": 0,
  "cameras": 0,
  "lights": 0,
  "variants": [],
  "bounds": {
    "size": [
      1,
      2,
      0
    ],
    "center": [
      0.5,
      1,
      0
    ]
  },
  "warn": []
}

Other warnings glb gives (from scripts/lib/glb.mjs): required extensions GLTFLoader r186 does not handle, files over 5 MB and over 10 MB, over 500k and over 2M triangles, over 200 draw calls, textures over 2048 px, more than 32 MB of uncompressed texture memory without KTX2, primitives without normals, a model over 100 units or under 0.01 units across, and missing external images or .bin buffers. needs: lines name the decoder an extension needs.

kb

tw kb search "transparency sorting"
transparency-and-blending  (topic)  Pick the transparency by its cause (coverage, transmission, glow) before touching transparent: alphaTest, alphaHash, alphaToCoverage, transmission, additive blending, and the sorting traps.
spark  (library)  The most capable three.js Gaussian-splat engine, with streaming LoD and a GPU virtual memory pool; WebGL2 only in official releases, versus r186's native WebGPU splat renderer.
splat-scenes  (scenario)  Split by scene size: three r186's native WebGPU splat renderer for small to medium scenes, Spark on WebGL2 for large or streamed ones; KHR_gaussian_splatting is now ratified.
gaussian-splats  (topic)  The native r186 splat renderer versus Spark, splat file formats, and which one to reach for by scene size.
renderer-choice  (topic)  Which renderer to default to per scenario in r186, why, and what breaks if you pick the wrong one.
performance  (topic)  Draw call and triangle budgets by target device, instancing and batching, and the measurements that catch a slow scene in text.
post-processing  (topic)  EffectComposer for WebGLRenderer versus RenderPipeline and TSL display nodes for WebGPURenderer, and why they never mix.
games  (scenario)  Plain three.js plus Rapier is the default game stack; a fixed-timestep loop, an action-map input layer, and headless hooks that let a test step the game deterministically.
tw kb show models-for-the-web --section Budgets
# 3D models for the web (topics/models-for-the-web.md; current, >=r180)

## Budgets
Guidance for one model on a page, not a spec (whole-scene numbers are in `performance`):

| Target | Triangles | Draw calls | Textures | File |
|---|---|---|---|---|
| Phone, one hero model | 50k to 100k | under 10 | 1024 to 2048 px, KTX2 | 2 to 5 MB |
| Desktop product viewer | 100k to 300k | under 20 | 2048 px (4096 only for a true hero), KTX2 | 5 to 10 MB |
| Game prop in a kit | 500 to 5k | 1 (shared material) | atlas or trim sheet | under 500 KB |

polywright's `web-threejs` check target warns above 150k triangles, 2048 px images and 10 MB.
tw kb list --kind rule
current-vs-legacy  (rule)  What counts as current in r186, what is the WebGL path (current, feature-light), what is legacy, and the release each old pattern changed in, for porting and for reading old code.
verification-ladder  (rule)  Prove a three.js page works with the cheapest evidence first; lint, console and scene text, model report, then one small image, and what each rung costs in tokens.
when-3d-is-justified  (rule)  Build a 3D chart only for data with three real axes or real geometry, always rotatable, always paired with an exact-value view; hand decorative 3D back to 2D.

kb index regenerates kb/INDEX.md and kb/index.json, kb validate [--strict] checks every entry against kb/SCHEMA.md, and kb note <slug> "<text>" adds a dated note. More on The knowledge base.

new, templates and vendor

tw new html-importmap site
copied html-importmap to <work>\site
  next: serve the folder with any static server (module imports do not load from file://)
  next: node <plugin>/scripts/tw.mjs check site

--force writes into a folder that is not empty; templates marked "vendor": true (product-viewer, scroll-hero) are vendored unless --no-vendor. tw templates lists the starters: see Templates.

tw vendor site/ --dry-run
<work>\site\index.html: 4 file(s), 2116 KB (dry run, nothing written)
  three -> ./vendor/three@0.186.1/build/three.module.js
  three/addons/ -> ./vendor/three@0.186.1/examples/jsm/

Without --dry-run it copies those pinned CDN modules, their own imports and the files they fetch by new URL(..., import.meta.url) (the r186 Draco and KTX2 decoders) into vendor/, and rewrites the import map. The bytes come from node_modules, the tw cache or npm pack, never the CDN.

deprecations and versions

With three installed in dev/ (npm ci there):

tw deprecations
three 0.186.1: 59 deprecation marker(s), 53 covered by lint rules, 6 skipped on purpose, 0 pending
tw versions --check

On 2026-10-26 it printed (the list changes as packages release):

@deck.gl/core                  latest 9.4.1        BEHIND  (9.4.0 in 1 place)  also: beta 10.0.0-alpha.1
@google/model-viewer           latest 4.4.0        BEHIND  (4.3.1 in 1 place)
@iwsdk/core                    latest 1.1.0        BEHIND  (1.0.0-rc.2 in 1 place)  also: next 1.2.0-rc.0
@needle-tools/engine           latest 5.1.16       BEHIND  (5.1.13 in 1 place)
@react-three/fiber             latest 9.8.2        BEHIND  (9.8.1 in 2 places)  also: canary 10.0.0-canary.58acabc, alpha 10.0.0-alpha.6
@sparkjsdev/spark              latest 2.4.0        BEHIND  (2.2.0 in 1 place)
@threlte/core                  latest 8.7.0        BEHIND  (8.6.1 in 1 place)
@tresjs/core                   latest 5.12.0       BEHIND  (5.9.0 in 1 place)
@types/three                   latest 0.187.0      BEHIND  (0.186.0 in 2 places)
@vitejs/plugin-react           latest 6.3.0        BEHIND  (6.1.1 in 1 place)
3d-tiles-renderer              latest 0.5.4        BEHIND  (0.5.3 in 1 place)
gsap                           latest 3.15.1       BEHIND  (3.15.0 in 1 place)  also: beta 4.0.0-beta.4
jolt-physics                   latest 1.1.1        BEHIND  (1.1.0 in 1 place)
lenis                          latest 1.3.27       BEHIND  (1.3.26 in 1 place)  also: dev 2.0.0-dev.6
plotly.js                      latest 4.3.0        BEHIND  (4.1.1 in 1 place)
postprocessing                 latest 6.39.6       BEHIND  (6.39.5 in 1 place)  also: alpha 7.0.0-alpha.4, beta 7.0.0-beta.16
react                          latest 19.3.1       BEHIND  (19.3.0 in 1 place)
react-dom                      latest 19.3.1       BEHIND  (19.3.0 in 1 place)
three                          latest 0.187.0      BEHIND  (0.186.1 in 14 places)
three-mesh-bvh                 latest 0.9.18       BEHIND  (0.9.15 in 1 place)
troika-three-text              latest 0.53.1       BEHIND  (0.52.5 in 1 place)
vite                           latest 8.3.8        BEHIND  (8.3.1 in 2 places)  also: beta 8.4.0-beta.1
@dimforge/rapier3d-compat      latest 0.21.0       ok  (0.21.0 in 1 place)
@gltf-transform/cli            latest 4.5.1        ok  (4.5.1 in 1 place)
@pixiv/three-vrm               latest 3.5.5        ok  (3.5.5 in 1 place)
@react-three/a11y              latest 3.0.0        ok  (3.0.0 in 1 place)
@react-three/drei              latest 10.7.9       ok  (10.7.9 in 2 places)  also: alpha 11.0.0-alpha.7
@react-three/rapier            latest 2.2.0        ok  (2.2.0 in 1 place)
@theatre/core                  latest 0.7.2        ok  (0.7.2 in 1 place)
@types/react                   latest 19.3.0       ok  (19.3.0 in 1 place)
@types/react-dom               latest 19.3.0       ok  (19.3.0 in 1 place)
camera-controls                latest 3.1.2        ok  (3.1.2 in 1 place)
cannon-es                      latest 0.20.0       ok  (0.20.0 in 1 place)
globe.gl                       latest 2.46.2       ok  (2.46.2 in 1 place)
gltfpack                       latest 1.3.0        ok  (1.3.0 in 1 place)
lil-gui                        latest 0.21.0       ok  (0.21.0 in 1 place)
stats-gl                       latest 4.2.3        ok  (4.2.3 in 1 place)
three-stdlib                   latest 2.36.1       ok  (2.36.1 in 1 place)
typescript                     latest 7.0.2        ok  (7.0.2 in 2 places)  also: beta 7.1.0-beta, next 7.1.0-dev.20261118.1
22 package(s) behind: refresh those kb entries and templates (threewright-curate), then tw kb validate

Exit code 1 when anything is behind.

doctor

tw doctor checks Node, Chrome, ffmpeg, npm, CDN reach, and WebGL and WebGPU in headless Chrome; its output is on Getting started.

Clone this wiki locally