react-three-fiber
预览截图
安装方式
先用 Prompt 核对来源与依赖。也可下载安装包。
用 AI 助手安装
复制提示词,让助手先核对固定版本和依赖。
查看 Prompt收起 Prompt
先检查当前 Agent 是否已安装 SkillPI Skill Finder。如果尚未安装,请按官方仓库的说明安装并启用:https://github.com/Findskills/skillpi。然后使用 Skill Finder 打开此 SkillPI 详情页并定位 "react-three-fiber":https://skillpi.com/zh/skills/deepskill-81b51ea20ce2c642571943286fc0cce4a57304b3928ebbe0a6d4f8b9465edcb5。安装前核对上游来源和版本:https://github.com/midudev/autoskills。来源不一致时停止并说明差异。核对通过后,用 Skill Finder 安装目标 Skill,并报告安装路径和来源版本。
来源与配置
github.com
配置方式待核实
请查看原始来源中的适用工具、依赖和权限要求。
安装实测待补充
React Three Fiber 的 3D 渲染器,供 json-render 使用。用于在使用 @json-render/react-three-fiber 时,按 JSON 规范构建 3D 场景并渲染网格、灯光、模型与环境,或在将 Three.js 与 json-render 目录集成时使用。
介绍来源: third_party · midudev · 0.0.1 参考来源
SkillPi 解读
- 能完成的任务
- 重现三翼三维渲染器用于json-resanders. 与@json-render/react-Tree-fiber合作时使用,从JSON光谱构建3D场景,使meshes/lights/models/environments,或将3.js与json-render目录集成.
- 实测状态
- 未测试
文件浏览
Frontmatter
name: react-three-fiber
description: React Three Fiber 3D renderer for json-render. Use when working with @json-render/react-three-fiber, building 3D scenes from JSON specs, rendering meshes/lights/models/environments, or integrating Three.js with json-render catalogs.@json-render/react-three-fiber
React Three Fiber renderer for json-render. 19 built-in 3D components.
Two Entry Points
| Entry Point | Exports | Use For |
|---|---|---|
@json-render/react-three-fiber/catalog |
threeComponentDefinitions |
Catalog schemas (no R3F dependency, safe for server) |
@json-render/react-three-fiber |
threeComponents, ThreeRenderer, ThreeCanvas, schemas |
R3F implementations and renderer |
Usage Pattern
Pick the 3D components you need from the standard definitions:
import { defineCatalog } from "@json-render/core";
import { schema } from "@json-render/react/schema";
import { threeComponentDefinitions } from "@json-render/react-three-fiber/catalog";
import { defineRegistry } from "@json-render/react";
import { threeComponents, ThreeCanvas } from "@json-render/react-three-fiber";
// Catalog: pick definitions
const catalog = defineCatalog(schema, {
components: {
Box: threeComponentDefinitions.Box,
Sphere: threeComponentDefinitions.Sphere,
AmbientLight: threeComponentDefinitions.AmbientLight,
DirectionalLight: threeComponentDefinitions.DirectionalLight,
OrbitControls: threeComponentDefinitions.OrbitControls,
},
actions: {},
});
// Registry: pick matching implementations
const { registry } = defineRegistry(catalog, {
components: {
Box: threeComponents.Box,
Sphere: threeComponents.Sphere,
AmbientLight: threeComponents.AmbientLight,
DirectionalLight: threeComponents.DirectionalLight,
OrbitControls: threeComponents.OrbitControls,
},
});
Rendering
ThreeCanvas (convenience wrapper)
<ThreeCanvas
spec={spec}
registry={registry}
shadows
camera={{ position: [5, 5, 5], fov: 50 }}
style={{ width: "100%", height: "100vh" }}
/>
Manual Canvas setup
import { Canvas } from "@react-three/fiber";
import { ThreeRenderer } from "@json-render/react-three-fiber";
<Canvas shadows>
<ThreeRenderer spec={spec} registry={registry}>
{/* Additional R3F elements */}
</ThreeRenderer>
</Canvas>
Available Components (19)
Primitives (7)
Box-- width, height, depth, materialSphere-- radius, widthSegments, heightSegments, materialCylinder-- radiusTop, radiusBottom, height, materialCone-- radius, height, materialTorus-- radius, tube, materialPlane-- width, height, materialCapsule-- radius, length, material
All primitives share: position, rotation, scale, castShadow, receiveShadow, material.
Lights (4)
AmbientLight-- color, intensityDirectionalLight-- position, color, intensity, castShadowPointLight-- position, color, intensity, distance, decaySpotLight-- position, color, intensity, angle, penumbra
Other (8)
Group-- container with position/rotation/scale, supports childrenModel-- GLTF/GLB loader via url propEnvironment-- HDRI environment map (preset, background, blur, intensity)Fog-- linear fog (color, near, far)GridHelper-- reference grid (size, divisions, color)Text3D-- SDF text (text, fontSize, color, anchorX, anchorY)PerspectiveCamera-- camera (position, fov, near, far, makeDefault)OrbitControls-- orbit controls (enableDamping, enableZoom, autoRotate)
Shared Schemas
Reusable Zod schemas for custom 3D catalog definitions:
import { vector3Schema, materialSchema, transformProps, shadowProps } from "@json-render/react-three-fiber";
import { z } from "zod";
// Custom 3D component
const myComponentDef = {
props: z.object({
...transformProps,
...shadowProps,
material: materialSchema.nullable(),
myCustomProp: z.string(),
}),
description: "My custom 3D component",
};
Material Schema
materialSchema = z.object({
color: z.string().nullable(), // default "#ffffff"
metalness: z.number().nullable(), // default 0
roughness: z.number().nullable(), // default 1
emissive: z.string().nullable(), // default "#000000"
emissiveIntensity: z.number().nullable(), // default 1
opacity: z.number().nullable(), // default 1
transparent: z.boolean().nullable(), // default false
wireframe: z.boolean().nullable(), // default false
});
Spec Format
3D specs use the standard json-render flat element format:
{
"root": "scene",
"elements": {
"scene": {
"type": "Group",
"props": { "position": [0, 0, 0] },
"children": ["light", "box"]
},
"light": {
"type": "AmbientLight",
"props": { "intensity": 0.5 },
"children": []
},
"box": {
"type": "Box",
"props": {
"position": [0, 0.5, 0],
"material": { "color": "#4488ff", "metalness": 0.3, "roughness": 0.7 }
},
"children": []
}
}
}
Dependencies
Peer dependencies required:
@react-three/fiber>= 8.0.0@react-three/drei>= 9.0.0three>= 0.160.0react^19.0.0zod^4.0.0
版本历史
-
v0.4.1
GitHub ↗
原版更新说明
### 🐛 Bug Fixes - fix(autoskills): stop multiSelect from duplicating lines on redraw [`cc80891`](https://github.com/midudev/autoskills/commit/cc80891)
-
v0.4.0
GitHub ↗
原版更新说明
### ⚠️ Breaking Changes - refactor(autoskills)!: drop Deno support [`d6f4301`](https://github.com/midudev/autoskills/commit/d6f4301) ### ✨ Features - feat(registry): re-review 41 pending skills with the new pipeline [`aff4e3c`](https://github.com/midudev/autoskills/commit/aff4e3c) - feat(sync): let an AI adjudicate flagged skills instead of a human [`98d42aa`](https://github.com/midudev/autoskills/commit/98d42aa) - fix(registry): add official FastAPI skill and merge duplicate techs [`f58a99c`](https://github.com/midudev/autoskills/commit/f58a99c) - feat(registry): sync skills and drop those removed upstream [`1228788`](https://github.com/midudev/autoskills/commit/1228788) - feat(autoskills): add ui command to browse installed skills [`1e5a14a`](https://github.com/midudev/autoskills/commit/1e5a14a) - Add fastmcp skill for Python MCP server development FastMCP is the standard Python framework for building MCP servers. This skill teaches production patterns verified against FastMCP 3.2.x, specifically addressing APIs that LLMs hallucinate (server.state, on_startup, context.name in middleware — none of which exist). Detection: 'fastmcp' pattern in pyproject.toml/requirements.txt Validation: 97.1% (agentskills.io spec checker) [`8caa407`](https://github.com/midudev/autoskills/commit/8caa407) - feat: add ElysiaJS support with skills registry documentation and icon [`b2e1400`](https://github.com/midudev/autoskills/commit/b2e1400) ### 📦 Other Changes - test(cli): ignore FORCE_COLOR when checking CLI output [`97692cd`](https://github.com/midudev/autoskills/commit/97692cd) - chore(release): skip merge commits in the changelog [`5ba3aa3`](https://github.com/midudev/autoskills/commit/5ba3aa3) - docs: document ui command, missing flags and the AI review [`0ad8885`](https://github.com/midudev/autoskills/commit/0ad8885) - chore(sync): review skills with Claude and accept --only lists [`5740dd0`](https://github.com/midudev/autoskills/commit/5740dd0) - perf(autoskills): download skill files in parallel [`0293487`](https://github.com/midudev/autoskills/commit/0293487) - build(deps): update Astro 7, Tailwind, oxc, TypeScript 7 and pnpm [`18de798`](https://github.com/midudev/autoskills/commit/18de798)
-
v0.3.6
GitHub ↗
原版更新说明
### ✨ Features - feat(autoskills): detect instantdb projects [`c86be97`](https://github.com/midudev/autoskills/commit/c86be97) - feat(autoskills): detect bash scripts [`fe57ba0`](https://github.com/midudev/autoskills/commit/fe57ba0) ### 🐛 Bug Fixes - fix(autoskills): normalize registry paths for downloads [`8477028`](https://github.com/midudev/autoskills/commit/8477028) ### 📦 Other Changes - chore(registry): update synced skill manifest [`442cf12`](https://github.com/midudev/autoskills/commit/442cf12) - chore(registry): sync turborepo skill [`3fadf74`](https://github.com/midudev/autoskills/commit/3fadf74) - chore(registry): sync backend and rails skills [`db3b50b`](https://github.com/midudev/autoskills/commit/db3b50b) - chore(registry): sync frontend and mobile skills [`49550f5`](https://github.com/midudev/autoskills/commit/49550f5)
-
v0.3.5
GitHub ↗
原版更新说明
### ✨ Features - feat(cli): surface skill security warnings [`aba2acf`](https://github.com/midudev/autoskills/commit/aba2acf) - feat(autoskills): display registry security checks [`df77e04`](https://github.com/midudev/autoskills/commit/df77e04) - feat(swiftui): support selecting xctrace runs [`050801e`](https://github.com/midudev/autoskills/commit/050801e) - feat(rails-upgrade): add legacy guide and ci sync workflow [`468fde3`](https://github.com/midudev/autoskills/commit/468fde3) - feat(cloudflare): add flagship feature flag references [`f1b429d`](https://github.com/midudev/autoskills/commit/f1b429d) - feat(azure-diagnostics): add app service and messaging guides [`260ddd4`](https://github.com/midudev/autoskills/commit/260ddd4) - feat(autoskills): add curated Bun skill [`2760757`](https://github.com/midudev/autoskills/commit/2760757) ### 🐛 Bug Fixes - fix(ui): hide single selection group header [`e5c26da`](https://github.com/midudev/autoskills/commit/e5c26da) ### 📦 Other Changes - chore(skills): refresh registry skill guidance [`5d301d5`](https://github.com/midudev/autoskills/commit/5d301d5)
-
v0.3.4
GitHub ↗
原版更新说明
### ✨ Features - feat(autoskills): add verbose install tracing [`cc409f8`](https://github.com/midudev/autoskills/commit/cc409f8) - feat(autoskills): fall back to main registry mirror [`f7d9155`](https://github.com/midudev/autoskills/commit/f7d9155) ### 🐛 Bug Fixes - fix(release): normalize repository URL for changelog and release summary links [`832819e`](https://github.com/midudev/autoskills/commit/832819e) ### 📦 Other Changes - style(autoskills): format code for improved readability [`a5a3f11`](https://github.com/midudev/autoskills/commit/a5a3f11)
此处仅展示最近 5 个版本。 在原站查看完整版本历史 ↗
当前收录版本
0.0.1
质量评测
满分100 · 来自 SkillPi LAB 实验室的评测报告。
亮点
- 提供 19 个内置 3D 组件,覆盖 primitives/lights/other 完整类别
- 支持 JSON 规范构建 3D 场景,解决实际工程痛点
- 适用于 json-render 生态系统集成,具有明确实用价值
亮点
- description 清晰描述多种使用场景和触发条件
- 覆盖 @json-render/react-three-fiber 使用、JSON 规范构建、Three.js 集成等变体
- 触发词边界清晰,无歧义
待提升项
-
缺少 When to Use 章节 原报告严重程度:轻微
文档结构完整但缺少明确的 When to Use 使用场景说明章节
改进建议:建议添加 When to Use 章节,明确说明适用场景和使用时机
亮点
- 文档结构清晰,包含 Usage Pattern、Rendering、Components 等完整章节
- 提供完整的 TypeScript 代码示例和 JSON 规范示例
- frontmatter 完整,单文件长度适中
亮点
- 工具来源明确,提供两个入口点适应不同场景
- 参数定义清晰,各组件 props 详细说明
- 依赖项完整列出,包含所有必要的 peer dependencies
- 提供共享 schemas 支持自定义组件开发
取前四项原始分值的算术平均,四舍五入取整。可通过收录报告核对各项评分与说明,运行记录需单独查证。
正文静态检测
100 / 100 · skillpi-20261123-no-r3-v1
正文未命中当前规则。
分数仅反映正文中的规则命中,供使用前参考。附件与运行行为不在此评分范围内。
权限与使用前检查
根据当前主文档自动整理,命中内容可能是示例或防护说明;不是实际权限声明,也未覆盖附件、外部依赖或运行行为。
未从主文档识别到上述常见操作,不能据此判断无需权限或没有风险。
安全评级与访问范围
safe · 静态证据核验,不代表运行安全保证。
使用前请由宿主核对并授权实际文件读写、外部服务和联网目的地;本站的核验不会授予任何运行权限。
用户讨论
还没有已核实的点评。