Releases: mrousavy/nitro
Releases · mrousavy/nitro
Release 0.21.0
0.21.0 (2025-01-09)
✨ Features
- Add new
ArrayBuffer
APIs (copy()
,wrap()
,allocate()
,toData()
) (#463) (a06c7d4) - New Callback implementation that extends
() -> T
in Kotlin (faster!) (#470) (07d96a0) - Throw a better error message when using wrong imports (#467) (96e7716)
- Add definition to check if generated CMake is building the code (#466) (bf19f7d)
🐛 Bug Fixes
- Fix passing function inside object on Android (
toCpp()
) (#453) (57336f4) - Use UNIX paths for CMake file, even on Windows (
\
->/
) (#451) (3a6d46d) - Filter out duplicates for CMake extension (#462) (d5b9341)
- Remove unused Kotlin OnLoad (#460) (3795f5a)
- Update specs for new copyright year (#461) (e641d55)
📚 Documentation
Release 0.20.1
Release 0.20.0
0.20.0 (2024-12-20)
✨ Features
- Create statically compiled Swift closure wrapper to avoid C-style function pointers (#440) (699e138)
💨 Performance Improvements
- Create
PromiseHolder<T>
(#439) (00e9db4) - Mark all types that are used only in
std::shared_ptr<T>
asSWIFT_NONCOPYABLE
(#435) (196fc9d) - Move more stuff into closures (#434) (745e57e)
🐛 Bug Fixes
Release 0.19.0
0.19.0 (2024-12-18)
✨ Features
- Allow
std::future
to go bi-directional (using newPromise
impl) (#411) (283f1f5) - Default-calculate
getSizeOf(...)
so the user doesn't have to (#429) (5b510b8) - Implement callbacks that return a value in Swift/Kotlin 🥳 (#417) (4b54687)
- Implement proper type-erasure inheritance in Swift (#427) (50e0de3)
- Implement Swift errors 🥳 (#430) (5b3fa6c)
- Remove
hybridContext
andmemorySize
from Swift HybridObjects (make them optional) (#420) (6b85f08) - Remove
HybridContext
for simpler Swift bridges (#428) (70116b5) - Use
std::shared_ptr<Promise<T>>
instead ofstd::future<T>
for callbacks that return a value (#412) (ea2c070)
🐛 Bug Fixes
- Add workaround for error messages on Android (#408) (27e8cbb)
- Delete
HybridObject
copy & move ctors (#402) (5147fc7) - Fix catching
std::runtime_error
on Android (a90e3e4) - Fix react and react-native dependency resolutions (#419) (518f2b2)
- Fix react being wildcarded to 19 (#416) (978c833)
- Only generate code if platform is actually used (#395) (fe96d24)
- Rename
TCxx
toT_cxx
to better hide it from user (#424) (e8b01d0) - Use a glob for
ignorePaths
(#409) (94e0214)
📚 Documentation
Release 0.18.2
0.18.2 (2024-12-05)
✨ Features
- Add
nitrogen init <moduleName>
to create new Nitro Modules with template (#392) (583942f) - Add a
nitro.schema.json
schema to validatenitro.json
files (#390) (f7802e2) - Add native
NITRO_VERSION
to C++ codebase and warn if it's out of sync (#398) (04e73d8)
🐛 Bug Fixes
- Check
std::exception_ptr
for null (#381) (b916d5f) - Remove
packages/template
from bun workspace (#396) (c423cd3) - Replace placeholders to make them windows compatible (
<<*>>
->$$*$$
) (#385) (4ffa3ae)
📚 Documentation
Release 0.18.1
Release 0.18.0
0.18.0 (2024-11-27)
✨ Features
🐛 Bug Fixes
- Add
react-native-nitro-modules
peerDependency to template (12276b8) - Catch cases where a
Promise<T>
could potentially be rseolved twice (#362) (ed24de6) - Fix moving
sharedFunction
after first callback call (d0052ec) - Fix Promise rejections not having a message by using
std::exception_ptr
to avoid C++ object slicing (#369) (b069fb6) - Fix ref counting with recursive mutex (#368) (0747e09)
- Generate a shadow
ordinal
field for Kotlin Enums (#360) (7a32224)
Release 0.17.0
0.17.0 (2024-11-19)
As promised, this release is all about Promises! 🪄✨
❗️ Breaking
- For C++ Hybrid Objects:
std::future<T>
is nowPromise<T>
!
✨ Features
- Allow
ThreadPool
to grow dynamically (#345) (f94cfbc) - Enable ProGuard for release builds in Nitro Example (#342) (9f7728a)
- Add new
Promise<T>
implementation for C++ (#343) (8832bc5) - Use new, faster, simpler
Promise<T>
in Nitrogen (#349) (110dcbf) - Allow awaiting JS
Promise
in C++ (#354) (b6277ea) - Support awaiting JS
Promise
in Kotlin and Swift (#355) (6da4f98)
💨 Performance Improvements
🐛 Bug Fixes
- Fix Promise calls being stuck in rare cases when scheduling a lot of promises at once (#345) (f94cfbc)
- Make
Promise
catch anyThrowable
instead ofError
subclass (#337) (d76d0c0) - Fix Variants being stripped in release (#352) (8c09f6d)
- Fix "legacy"
enum
s breaking Swift compiler (#346) (cb9cf99) - Don't test
bounceChild(Base)
in release because that is optimized away (#353) (3626cb3) - Fix
Promise::awaitFuture
actually locking threads (#347) (8cd7a29) - Fix
Promise<void>
generation on Android (#357) (023c1ab)
📚 Documentation
- Add "Events" info to Callbacks docs page (ce4c415)
- Add
TestObject.nitro.ts
to example playground (b824959) - Add latest release to docs (728ea5c)
- Add Vercel analytics to docs (#332) (834a2ff)
- Clean up unused images (#334) (e461b17)
- Update docs to use new
Promise<T>
type instead ofstd::future<T>
(#348) (e931834)