Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebGPURenderer: Tree-shaking 1/2 - revision #29250

Merged
merged 7 commits into from
Aug 29, 2024
Merged

WebGPURenderer: Tree-shaking 1/2 - revision #29250

merged 7 commits into from
Aug 29, 2024

Conversation

sunag
Copy link
Collaborator

@sunag sunag commented Aug 29, 2024

Related issue: #29187, #29187 (comment)

Description

  • Added a lot of /*@__PURE__*/
  • Rename registerNodeClass -> registerNode
  • Added registerNodeMaterial
  • registerNode & registerNodeMaterial -- Introduce support for tree-shaking
  • Fix node.type and nodeMaterial.type

Copy link

📦 Bundle size

Full ESM build, minified and gzipped.

Filesize dev Filesize PR Diff
685.4 kB (169.7 kB) 685.4 kB (169.7 kB) +0 B

🌳 Bundle size after tree-shaking

Minimal build including a renderer, camera, empty scene, and dependencies.

Filesize dev Filesize PR Diff
462 kB (111.4 kB) 462 kB (111.4 kB) +0 B

@sunag sunag marked this pull request as ready for review August 29, 2024 04:13
@sunag sunag added this to the r168 milestone Aug 29, 2024
@sunag sunag added WebGPU TSL Three.js Shading Language labels Aug 29, 2024
@sunag sunag merged commit 881073e into mrdoob:dev Aug 29, 2024
12 checks passed
@sunag sunag deleted the dev-rev2 branch August 29, 2024 04:25
@sunag sunag mentioned this pull request Aug 29, 2024
11 tasks
@sunag sunag mentioned this pull request Sep 1, 2024
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
TSL Three.js Shading Language WebGPU
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant