[GH-ISSUE #408] Move 3D module to separate @opentui/3d package #872

Open
opened 2026-03-14 08:53:21 +03:00 by kerem · 4 comments
Owner

Originally created by @remorses on GitHub (Dec 11, 2025).
Original GitHub issue: https://github.com/anomalyco/opentui/issues/408

Installing @opentui/core pulls in 84 packages including three, planck, bun-webgpu, and rapier due to optionalDependencies.

Most users only need the core TUI functionality. Moving src/3d/ to a separate @opentui/3d package would keep the core package lightweight and let users opt-in to 3D features explicitly.

Originally created by @remorses on GitHub (Dec 11, 2025). Original GitHub issue: https://github.com/anomalyco/opentui/issues/408 Installing @opentui/core pulls in 84 packages including three, planck, bun-webgpu, and rapier due to optionalDependencies. Most users only need the core TUI functionality. Moving src/3d/ to a separate @opentui/3d package would keep the core package lightweight and let users opt-in to 3D features explicitly.
Author
Owner

@remorses commented on GitHub (Dec 11, 2025):

I can work on a PR if you agree

<!-- gh-comment-id:3642509279 --> @remorses commented on GitHub (Dec 11, 2025): I can work on a PR if you agree
Author
Owner

@kommander commented on GitHub (Dec 11, 2025):

Would have to split up the examples then as well though as there are 3d examples. Which would mean either separate prebuilt example apps, which I don't like, or moving the examples into their own package as well and building from there. Needs pipeline adjustments then as well to publish these with the GitHub release. The examples wouldn't be a package though? So needs apps/examples parallel to packages?

Could get out of hand. Can we just make the dependencies dev dependencies for now? Or does it still install them all the time then?

<!-- gh-comment-id:3642541572 --> @kommander commented on GitHub (Dec 11, 2025): Would have to split up the examples then as well though as there are 3d examples. Which would mean either separate prebuilt example apps, which I don't like, or moving the examples into their own package as well and building from there. Needs pipeline adjustments then as well to publish these with the GitHub release. The examples wouldn't be a package though? So needs `apps/examples` parallel to `packages`? Could get out of hand. Can we just make the dependencies dev dependencies for now? Or does it still install them all the time then?
Author
Owner

@remorses commented on GitHub (Dec 11, 2025):

Examples would remain where they are, we can just move the 3d code into another package and keep examples inside core folder.

These would import from @opentui/3d instead of relative imports, 3d would be installed as a workspace dev dependency

<!-- gh-comment-id:3642553963 --> @remorses commented on GitHub (Dec 11, 2025): Examples would remain where they are, we can just move the 3d code into another package and keep examples inside core folder. These would import from @opentui/3d instead of relative imports, 3d would be installed as a workspace dev dependency
Author
Owner

@kommander commented on GitHub (Dec 11, 2025):

If that works and the prebuilt examples are working correctly I don't see why not. Little weird to have the examples in core with dependency on another package, perspectively would move them.

<!-- gh-comment-id:3642689258 --> @kommander commented on GitHub (Dec 11, 2025): If that works and the prebuilt examples are working correctly I don't see why not. Little weird to have the examples in core with dependency on another package, perspectively would move them.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/opentui#872
No description provided.