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

LoaderUtils: Deprecate decodeText(). #28278

Merged
merged 3 commits into from May 6, 2024

Conversation

ycw
Copy link
Contributor

@ycw ycw commented May 4, 2024

This PR removes decodeText from source.
This PR deprecates LoaderUtils.decodeText()

According to caniuse, TextDecoder has >97% coverage globally., baseline 2017(safari)

Available polyfill package: https://www.npmjs.com/package/@loaders.gl/polyfills

I made a simple fiddle for testing the polyfill, it works for utf-8: https://jsfiddle.net/4onckv12/

@ycw ycw mentioned this pull request May 4, 2024
Copy link

github-actions bot commented May 4, 2024

📦 Bundle size

Full ESM build, minified and gzipped.

Filesize dev Filesize PR Diff
675.5 kB (167.5 kB) 675.7 kB (167.5 kB) +134 B

🌳 Bundle size after tree-shaking

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

Filesize dev Filesize PR Diff
454.8 kB (109.8 kB) 454.8 kB (109.8 kB) +0 B

@ycw ycw force-pushed the remove-decodetext-from-src branch from 3b3583c to 654514b Compare May 4, 2024 13:53
@ycw ycw changed the title Removes utility function decodeText from source Deprecates utility function LoaderUtils.decodeText() May 4, 2024
@ycw ycw requested a review from Mugen87 May 4, 2024 13:56
src/loaders/LoaderUtils.js Outdated Show resolved Hide resolved
@ycw ycw force-pushed the remove-decodetext-from-src branch from 654514b to 5a5b798 Compare May 4, 2024 15:33
@ycw ycw requested a review from Mugen87 May 4, 2024 15:35
@Mugen87 Mugen87 added this to the r165 milestone May 4, 2024
@Mugen87 Mugen87 changed the title Deprecates utility function LoaderUtils.decodeText() LoaderUtils: Deprecate decodeText(). May 6, 2024
@Mugen87 Mugen87 merged commit 79c3490 into mrdoob:dev May 6, 2024
8 of 12 checks passed
@ycw ycw deleted the remove-decodetext-from-src branch May 6, 2024 08:57
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.

None yet

2 participants