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

Tree-shaking: DataUtils #24218

Merged
merged 2 commits into from
Jun 13, 2022
Merged

Tree-shaking: DataUtils #24218

merged 2 commits into from
Jun 13, 2022

Conversation

pschroen
Copy link
Contributor

@pschroen pschroen commented Jun 9, 2022

Related issue: #24199

Troubleshooting the remaining side-effects, converted DataUtils to a singleton plain functions pattern to allow for tree-shaking, linted and tested with the rectarealight example.

@marcofugaro
Copy link
Contributor

We moved away from the "class with only static methods" pattern, could you do the same for DataUtils?

See #21651, #22267, and #22284

src/extras/DataUtils.js Outdated Show resolved Hide resolved
@marcofugaro
Copy link
Contributor

Perfect! Thanks guys

@mrdoob mrdoob added this to the r142 milestone Jun 13, 2022
@mrdoob mrdoob merged commit b39c33c into mrdoob:dev Jun 13, 2022
@mrdoob
Copy link
Owner

mrdoob commented Jun 13, 2022

Thanks!

@pschroen pschroen deleted the tree-shaking-datautils branch June 13, 2022 13:16
@joshuaellis joshuaellis mentioned this pull request Jul 18, 2022
3 tasks
abernier pushed a commit to abernier/three.js that referenced this pull request Sep 16, 2022
* Tree-shaking: DataUtils

* DataUtils: Convert to plain functions for tree-shaking
snagy pushed a commit to snagy/three.js-1 that referenced this pull request Sep 21, 2022
* Tree-shaking: DataUtils

* DataUtils: Convert to plain functions for tree-shaking
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants