Threlte 8
threlte.xyz
threlte.xyz
Threlte is a renderer and component library for using Three.js in a declarative and state-driven way in Svelte apps. It provides strictly typed components for deep reactivity and interactivity out-of-the-box.
It's suffice to say it was a whole lot of work and a great challenge to make use of Svelte 5. A lot of the important parts have been rewritten to make use of the new reactivity model, some APIs have been aligned with conventions introduced by Svelte 5 and type safety has been improved all over. Also this release includes the first alpha release of Threlte Studio which is what we call a spatial programming toolset.
If you're looking for an migration guide, it's here: https://threlte.xyz/docs/learn/advanced/migration-guides#thr...
Longer term, I would migrate away from the ".xyz" domain as it's (sadly) now become closely associated with the "Web3/Blockchain" space.
https://threlte.xyz/docs/learn/getting-started/introduction
Threlte is a renderer and component library for using Three.js in a declarative and
state-driven way in Svelte apps. It provides strictly typed components for deep
reactivity and interactivity out-of-the-box.I'm interested in computing light that trees receive and want to be able to visualize it but also have even leaves that aren't in view to continue to receive light during the simulation.
It might get computationally expensive to point that raycaster in many directions and intersect with all leaves. I'm not aware of a way to do "bulk" raycasting in three.js yet.
Separately, the lighting / shadows can compute visually shadow and lighting. But I'm not aware of a way to then easily measure out how much of a mesh is in shadow.
I am also interested in tree simulation -- I'm tinkering on a arborist/lumberjack game where you trim / cut down trees :)
Threlte 8 is yet another example of how little backward compatibility matters to JS library developers and adopting such a library can be a costly endeavor.
Backward compatibility is readily and easily sacrificed in the name of ... what exactly?
Other examples:
MUI (Material UI lib) - some kudos are warranted for the existence of a migration tool but there are too many migrations that are not trivial or easy to change.
Angular - the OG of "All your code is now worthless, adopt or die" (some may be too young to remember Angular v1)
Vue - completely unnecessary renames and plenty of breaking changes between v2 and v3
The list goes on and on.
And it is not like you can afford to stay behind several major versions either. Eventually a CVE pops up that will not be fixed in older versions or the dependency tree will mess you up because you are relying on older versions that are incompatible with newer ones in some arcane 5 liner npm package.
Tread careful when choosing a JS library.
I get your sentiment though. I'm always for as little dependencies as possible. If you rely on Three.js in the first place, you're going to need to update regularly anyway since pretty much every version is a major version. Thanks for your feedback!
That said
I hate websites that highjack scrolls to show an animation, especially on a frontpage. I immediately dismiss a product I am planning to buy just because it has scroll animations, and go straight to a competitor.
https://www.youtube.com/live/Fn0_8iZGkLk?si=gVF5PUOTjJ83oJyS
Time code 17:20
Year? :)
https://stackoverflow.com/questions/2390230/do-copyright-dat...