jonobr1 / jonobr1/react-two.js

[Roadmap] Declarative Two.js web-scene feature parity

Open
#35 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
TypeScript
Stars
15
Forks
2
Avg merge
7h 7m
Merged PRs (30d)
3

Description

Goal

Track the remaining work required for a React application to reproduce a Two.js web scene declaratively and keep it correct through React updates.

This roadmap treats imperative access through useTwo() and refs as an escape hatch, not as proof that the React surface is complete.

Definition of feature complete

  • A representative Two.js scene can be expressed without manual parent.add(...) calls.
  • React remains authoritative after prop changes, prop removal, child reorder, reparenting, and unmount.
  • Masks, gradients, texture-backed objects, imported SVG, and custom/existing objects have lifecycle-safe declarative paths.
  • SVG, Canvas, and WebGL accept the documented configuration and produce equivalent scene structure where Two.js supports it.
  • Pointer targeting follows the rendered scene graph.
  • Every exported component has checked property and lifecycle coverage.

Foundation

  • #29
  • #30

Scene relationships and resources

  • #9
  • #31
  • #12

Object coverage and escape hatches

  • #10
  • #33

Canvas and importing

  • #32
  • #8

Interaction correctness

  • #34

Follow-on React ergonomics

These are valuable but are not blockers for core Two.js web-scene parity:

  • #11

React Native is a separate renderer/platform initiative and remains tracked independently in #6.

Already delivered

  • Core wrappers for the Two.js 0.8.23 drawable classes
  • SVG, Canvas, and WebGL renderer integration
  • useTwo and useFrame
  • Texture component from #1
  • Base pointer-event system from #16
  • ZUI integration from #7

Recommended sequence

  1. Land #29 first because ordering, ownership, replacement, and cleanup affect most later work.
  2. Complete property coverage (#30) alongside mask semantics (#9).
  3. Build resource composition (#31) and async texture loading (#12) on the shared lifecycle.
  4. Finish Canvas/import correctness (#32 and #8).
  5. Add Arc and the generic escape hatch (#10 and #33).
  6. Complete interaction parity in #34 against the reconciled scene graph.

Non-goals

  • Restoring the removed Canvas.container prop. The current styling API is intentional.
  • Requiring helper/gizmo or React Native work before declaring core web scene parity.
  • Wrapping every Two.js method as JSX when useTwo() or refs are the appropriate advanced API.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source files or tests are named; start by reading the linked work items in the recommended sequence, beginning with the foundation and remaining scene-relationship issues. The work is done when the definition-of-feature-complete criteria are met across declarative scene updates, resources, renderers, importing, interaction, and exported-component coverage.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.