Soundor 0.7.0
Release notes for Soundor 0.7.0.
4 changes — 2 features, 1 fix, 1 breaking change
Minor Changes
-
#108
b1a2699Thanks @dm-balakin! - Breaking: natively, plugin UIs run on Hermes, not QuickJS-NG:eval()andnew Function()throw, private class members andlet/constfollow the lowered semantics below, and a call into JavaScript that runs pastjuceRuntime({ timeLimit })(5 s by default) is stopped. Runtime authors: the CLI's UI bundle context gainsctx.ui.module(the ES module) besidectx.ui.entry(now the native CommonJS form), and the nativeRuntimeStatisticscounts collections instead of allocations. ThesoundorCLI needs Node^22.18.0 || >=24.11.0(Babel 8).The JUCE runtime runs JavaScript on Hermes's interpreter instead of QuickJS-NG (no JIT; no Static Hermes). A built plugin embeds its UI bundle as Hermes bytecode, compiled at build time by the
hermescof the same pinned Hermes build, and links the VM without its compiler;soundor devevaluates source and reloads as before. Hermes is built from source once per machine into Soundor's cache (several minutes, the first time), with hidden symbols, and its heap running out is an error instead of an abort: such a context fails from then on and is recreated on reload.Hermes has no ES modules, so the CLI now writes the UI bundle twice:
bundle.mjs, the ES module the Web runtime loads (ctx.ui.module), andbundle.js(ctx.ui.entry), the native runtime's form: a CommonJS module function with classes, block scoping, private members, async functions and async generators lowered for Hermes by@soundor/core's newtoNativeModule()(Babel).soundor:*imports and application sources are unchanged.What changes for plugin code running natively:
eval()and theFunctionconstructors throw (a built plugin has no compiler, andsoundor devfails the same way), so code generated at run time needs a form made at build time; private class members are properties keyed by symbols of their own (fast, but visible toObject.getOwnPropertySymbols(), and unchecked: reading one on another object givesundefined);let/consthave no temporal dead zone (reading one before its declaration givesundefined); on Linux,localeCompareand dates'toLocaleString()ignore the user's locale. Each context has a garbage-collector thread of Hermes's own. Built-ins Hermes lacks (FinalizationRegistry,queueMicrotask, Set methods, iterator helpers,toSorted,Promise.withResolvers, ArrayBuffertransfer()...) are provided; Atomics, SharedArrayBuffer, Float16Array,IntlandSymbol.speciesare not.RuntimeStatisticscounts garbage collections (collections) instead of allocator calls.A UI script that never returns no longer freezes the host for good:
juceRuntime({ timeLimit })(milliseconds, 5000 by default;false: none) bounds each call into JavaScript (a frame, an event, a timer, startup), past which the engine stops it with aTimeoutErrorJavaScript cannot catch; the error is logged and the context fails from then on, until the editor is opened again orsoundor devreloads. Natively,RuntimeOptions::timeLimitandjs::TimeLimitScope. Native objects behindsoundor:nativehandles are released on the UI thread, at the next tick after the collector finalizes their handles, never on the collector's own thread.Packages:
@soundor/config,@soundor/core,soundor. -
#112
2b03fd1Thanks @dm-balakin! - Add native springs with velocity-continuous retargeting, sequences, parallel and staggered programs, delays, repetition, directional keyframes, seeking and paint animations. Extend the existing React animation API and browser-owned Web Animation implementation without per-frame JavaScript callbacks.Packages:
@soundor/core,@soundor/react. -
#111
3fddefeThanks @dm-balakin! - Add native timing animations for opacity and ordered transforms, playback controls, completion promises, declarative Animated.View transitions and browser Web Animations.Packages:
@soundor/core,@soundor/react.
Patch Changes
-
#105
a436b85Thanks @dm-balakin! - UI updates cost what changed. Assigning a style it already has does not reach native code. A change that only looks different (a color, opacity) is drawn again but not laid out, text is measured again only when its font changes, and reading a style natively looks up only the properties it has. A view drawing a single shape with opacity needs no offscreen layer, and others a layer only the size of their box: 500 animated cells went from 22 ms to under 1 ms of rendering. The React renderer compares styles with what it set, not throughnode.style, and re-binds listeners or recomputes accessibility only when those props change.Packages:
@soundor/react.