threejs-impl-drei

threejs-impl-drei is a skill for Claude Code, Codex from Impertio-Studio/Three.js-Claude-Skill-Package. It costs 127 tokens per session (3,751 once invoked), scanned A, original, MIT.

A guide to Drei, a collection of ready-made helpers for React Three Fiber, which lets React applications display Three.js graphics. It covers camera controls, environment maps, text, loading, and repeated objects.

In plain words
What is it for?
Use it when adding controls, models, textures, fonts, HTML overlays, environment lighting, or performance helpers to a React Three Fiber scene.
Why use it?
It helps prevent loading crashes, invalid environment settings, broken pointer controls, and slow rendering from repeated meshes.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one. Also seen: mentions Claude Code.

Good fit Use it when adding controls, models, textures, fonts, HTML overlays, environment lighting, or performance helpers to a React Three Fiber scene.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add Impertio-Studio/Three.js-Claude-Skill-Package --skill threejs-impl-drei
Clone the repo
git clone --depth 1 https://github.com/Impertio-Studio/Three.js-Claude-Skill-Package

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for threejs-impl-drei

README.md
[![agentmods](https://agentmods.dev/badge/skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei/github.svg)](https://agentmods.dev/skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei)
Your own site
<a href="https://agentmods.dev/skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei"><img src="https://agentmods.dev/badge/skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for threejs-impl-drei

Your own site · 80×15
<a href="https://agentmods.dev/skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei"><img src="https://agentmods.dev/badge/skills/impertio-studio/three.js-claude-skill-package/threejs-impl-drei.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 127 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,751 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00127 $0.03751
Opus 5 $0.00063 $0.01876
Sonnet 5 $0.00025 $0.00750
Haiku 4.5 $0.00013 $0.00375

Measured 9d ago against content hash 5a985c6ffbf8, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

threejs-impl-drei scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/source/threejs-impl/threejs-impl-drei/SKILL.md · 485 lines

How it starts

The opening of the file, as written. The whole thing — 485 lines — stays where its author put it; the contents beside it link to each section on GitHub.

threejs-impl-drei

Quick Reference

Installation

npm install @react-three/drei @react-three/fiber three

Critical Warnings

ALWAYS wrap components that use loader hooks (useGLTF, useTexture, useFBX, useKTX2, useFont) in <Suspense fallback={...}>. Omitting Suspense causes the entire React tree to crash.

ALWAYS add makeDefault to your primary camera controls (<OrbitControls makeDefault />). Without makeDefault, Drei controls do NOT integrate with R3F's event system and pointer events break.

NEVER use an invalid Environment preset name. The ONLY valid presets are: apartment, city, dawn, forest, lobby, night, park, studio, sunset, warehouse.

NEVER forget to call .preload() for critical assets. Use useGLTF.preload('/model.glb') at module scope to start loading before component mount.

ALWAYS use <Instances> for rendering more than 100 identical meshes. Individual meshes cause one draw call each; instances batch them into one.


Controls

OrbitControls

The most common camera control. Orbit, zoom, and pan around a target.

import { OrbitControls } from '@react-three/drei'

<OrbitControls
  makeDefault           // ALWAYS add — integrates with R3F events
  enableDamping         // smooth movement
  dampingFactor={0.05}
  minDistance={2}
  maxDistance={20}
  minPolarAngle={0}
  maxPolarAngle={Math.PI / 2}  // prevent going below ground
/>

Other Controls

Component Use Case
CameraControls Full-featured camera (recommended for complex scenes)
MapControls Top-down map navigation (orbit restricted to vertical axis)
PresentationControls Drag-to-rotate with spring physics (product viewers)
ScrollControls Scroll-driven animation (pages prop sets scroll length)
TransformControls Translate/rotate/scale gizmo on selected objects
DragControls Drag objects in 3D space
KeyboardControls Keyboard input as React context
FaceControls Face-tracking camera movement

Read the full file on GitHub · 485 lines

Files

What ships with it

3 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 485 lines · 127 tokens per session scan A 5a985c6ffbf8

Subscribe to this mod's changes

threejs-impl-drei is a skill published in the GitHub repository Impertio-Studio/Three.js-Claude-Skill-Package (13 stars, last pushed 2mo ago), licensed MIT. It adds 127 tokens to every session and 3,751 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

typescript-style

Validate TypeScript/React code against style and architectural conventions.

peteski22/agent-pragma · 14 tokens

nextjs-on-cloudflare

Build, migrate, and deploy Next.js apps on Cloudflare Workers with vinext. Use when starting a Next.js project on Cloudflare, moving an existing app to Workers, choosing between vinext and OpenNext, or setting up vinext for Workers. For setup, migration, or deployment, install vinext's upstream skills with npx skills…

cloudflare/skills · 96 tokens

skillshare-ui-website-style

Skillshare frontend design system for the React dashboard (ui/) and Docusaurus website (website/). Use this skill whenever you: build or modify a dashboard page or component in ui/src/, style or layout website pages or custom CSS in website/, create new React components for the dashboard, add pages to the dashboard…

runkids/skillshare · 147 tokens

web-design-engineer

Build or redesign polished browser-rendered visual artifacts with HTML/CSS/JavaScript/React: pages, dashboards, prototypes, slide decks, animations, UI mockups, and data visualizations. Use for visual front-end creation, design-system exploration, design critique, or explicit browser acceptance / QA of a web artifact.…

ConardLi/garden-skills · 96 tokens

json-ui

CRITICAL: Use for json-ui component rendering and development. Triggers on: json-ui, json render, component catalog, report render, HTML report, I18nString, i18n, bilingual, language switch, dual language, PaperHeader, AuthorList, Abstract, MetricsGrid, Section, Highlight, Zod schema, catalog.ts, cli.ts…

actionbook/actionbook · 118 tokens

remotion-markup

Best practices for writing Remotion React Markup.

guanyang/open-agent-hub · 14 tokens