Moddable SDK 8.3 contains improvements made between June 3, 2026, and July 3, 2026.
This release of the Moddable SDK includes contributions from many developers building with Embedded JavaScript in extremely diverse ways. Thank you to everyone for sharing your experience, expertise, and time with the community.
ECMA-419 Fourth Edition is an International Standard!
The Ecma General Assembly of June 2026 officially declared ECMA-419 Fourth Edition as an international standard. The Moddable team has been deeply involved in the creation of this standard, collaborating with many other organizations and individuals, in Ecma TC53.
You can read the complete standard here. Even if you aren't the kind of person who regularly reads standards, it is worth a look to appreciate just the breadth and depth of APIs that are available to Embedded JavaScript developers.
ECMA-419 Fourth Edition is significant for several reasons:
- Standard Bluetooth LE JavaScript APIs for both central and peripheral (client and server) with broad functionality, significantly more capabilities than Web Bluetooth. Products can implement their Bluetooth support using JavaScript using a tiny fraction of the code required to do the same in C.
- Standard DNS-SD in JavaScript allows products to claim local names, advertise their network services, and discover compatible network services.
- Numerous refinements to make Embedded JavaScript developers even more powerful.
- The standard itself has been fully reworked in Ecmarkup, just like the JavaScript standard, ECMA-262. This makes the standard easier to navigate with integrated search, smart highlighting, hierarchical table of contents, cleaner formatting, pinning, and faster loading.
- TC53 is picking up the pace. Each previous edition required two years to prepare; the fourth edition took just one. We are optimistic that the adoption of Ecmarkup will allow the committee to maintain this shorter cadence.
All the new features in ECMA-419 Fourth Edition are already implemented in the Moddable SDK. You can start using them today.
Explicit Resource Management Lands
The Explicit Resource Management APIs are a set of new tools for ensuring that objects release their resources immediately when they are no longer needed. This capability is especially relevant to Embedded JavaScript developers because we typically work on resource-constrained devices.
The JavaScript language committee, TC39, recently advanced the Explicit Resource Management proposal to Stage 4, which means it will be incorporated into the language standard. Moddable implemented the features and has been testing them behind a flag. In this release, they are now enabled by default and available for everyone to use. The V8 team published a nice introduction. These features are also available in TypeScript.
The simplest way to use Explicit Resource Management is with the using keyword. Choose it in place of let or const for a disposable object so the instance is automatically disposed when it goes out of scope. In this example, there's no call to close() the file because that is taken care of automatically, even when the read() method throws an exception.
function loadFile(path) {
using file = device.file.openFile({path});
return file.read(file.status().size);
}Without Explicit Resource Management, the function is much more complex:
function loadFile(path) {
const file = device.file.openFile({path});
try {
const result = file.read(file.status().size);
file.close();
return result;
}
catch (e) {
file.close();
throw e;
}
}All ECMA-419 classes in the Moddable SDK can be used with Explicit Resource Manager, as they alias the ECMA-419 Base Class Patterns close() method to Explicit Resource Management's [Symbol.dispose]() method.
ESP-IDF Update Pending
ESP-IDF 6.0.2 is live. It fixes one known issue with BLE that Moddable SDK developers have encounterered. We've successfully tested it with the Moddable SDK and plan to migrate to it in our next Moddable SDK release.
Details
- ECMA-419
- All ECMA-419 classes support Explicit Resource Management by aliasing
[Symbol.dispose]toclose(). - crypt/digest implementations for PSA (ESP32, eventually Zephyr) and KCL (any target). Note that this API is not yet stable.
- UDP on macOS includes error codes in exceptions.
- Serial on macOS issues writable before readable.
- Asynchronous I2C
- BLE Peripheral implements
remoteAddressproperty anddisconnect()method (suggested by @stc1988). These are 5th Edition features.
- All ECMA-419 classes support Explicit Resource Management by aliasing
- Devices
- Pebble / Alloy
Healthmodule provides full access to Pebble OShealth_serviceAPIs.- Poco origin fixes #1626 (reported by @EvanDSanders).
- Add
process()to transform command lists (requested by @FeralFox) #1632 (Example in Pebble-Examples repository) - Fixes to header handling in proxy #1630 (contributed by @jplexer)
Buttonmodule rewritten to use Pebble OS click recognizers Moddable-OpenSource/pebble-examples#12 (suggested by @vincentezw)- Reenable logging to app console when not attached to debugger #1648 (reported by @jplexer)
- Moddable Display 6 build fixes
- ESP32, Pebble, and Pico set context correctly for touch
- ESP32, ESP8266, Pico, and Zephyr continue start-up after attempt to connect to Wi-Fi fails #1644 (reported by @stc1988)
- Windows now uses
TimerQueueforTimermodule to support longer timeouts and more timers #1638 (requested by @amao-cbw) - ESP32
- Pebble / Alloy
- XS JavaScript engine
- Enable Explicit Resource Management on all targets.
- Conformance improvements for Explicit Resource Management.
xsmcGet(),xsmcGetIndex(),xsmcGetAt()return boolean indicating whether property was found. Streamlines a common pattern in ECMA-419 constructors- Native stack overflow no longer reported as JavaScript stack overflow.
- String
trim*()methods only copy if something is trimmed. Array.from()andArray.fromAsync()don't throw on an undefined mapper argument #1645 (reported by @d01c2).- Conformance improvements for immutable
ArrayBufferproposal (reported by @erights, thanks to @gibson402). - Fix
for awaitin module body (top level).
- Enable Explicit Resource Management on all targets.
- Modules
EventSourceweb-compatibility improvements- CO5300 Display Driver
- Add GDEY037T03 ePaper display driver #1636 (contributed by @jplexer)
Modulesmodule supports namespace import- Commodetto
- Large glyphs render correctly after fixing overflow in font engine #1631 (reported by @FeralFox)
- When dividing buffer for async transmission, ensure buffer height remains mulitple of two (fixes garbage in CO5300 driver which requires height to be a multiple of two)
- Reject unsupported PNG files to avoid unexpected state #1639 (contributed by @rootvector2)
- BMF parsers updated to defend against invalid data #1643 (contributed by @rootvector2)
- zlib inflate's
push()method accepts optional output buffer to let the caller manage output buffers and output size - ChatAudioIO uses a larger native stack for the chat worker (default no longer enough in ESP-IDF v6) (reported by @stc1988) #1635
- Base64 module (deprecated) memory safety vulnerability fixed #1627 (contributed by @alhudz)
- DNS parser hardened with additional bounds checks #1628 (contributed by @rootvector2)
TextDecoderhardened against invalid data #1637 (contributed by @rootvector2)- GT911 touch driver
- Use
writeRead()to minimize I2C transactions - Implement
lengthconfiguration to indicate the maximum number of simultaneous touch points - Add asynchronous version of driver using Async I2C
- Add asynchronous version of driver using micro worker
- Use
- FT6206 touch driver correctly merges
configure()options #1646 (contributed by @stc1988)
- TypeScript
- Tools
mcpackautomatically creates EventSource global if used by packages.testmcnow uses ECMA-419 Wi-Fi.xstsupports d8 bundle format to enable module fuzzing with Fuzzilli.
- Examples
Contact Us
If you have questions or suggestions about anything here, please reach out:
- Start a new Discussion on our GitHub repository.
- Drop by our Gitter to chat.
- Contact us on X / Twitter at @moddabletech.