Releases: ArcadeMode/TypeShim
v1.4.0
Summary
- Performance optimizations and NativeAOT have yielded a performance boost of ~10x for codegen, which now runs in ~100ms on average runtimes used to be in the ~1s range.
- New feature: XML comments on members are now translated to TSDoc to add more information to the interop boundary, all member types and formatting tags supported in C# have been implemented
- Bugfix: constructor parameters that could be passed an initializer would generate TypeScript with errors
- Fewer allocations and LoC generated in C# code using Tasks
What's Changed
- Benchmarking & optimizing JIT and AOT builds by @ArcadeMode in #81
- Ship native binaries by @ArcadeMode in #83
- Nuget workflow by @ArcadeMode in #84
- AssemblyExports correction for ctor with initializer-compatible param by @ArcadeMode in #89
- Inlineable task conversions by @ArcadeMode in #90
- Remove TSHIM010 diagnostic by @ArcadeMode in #88
- Add JSDoc generation from C# XML documentation comments by @Copilot in #78
- Support comments on exported constructors by @Copilot in #91
- Initializer parameter naming by @ArcadeMode in #92
- Improved sample project by @ArcadeMode in #93
Full Changelog: v1.3.0...v1.4.0
v1.3.0
Summary
Support for Span and ArraySegment has been implemented and will present in TypeScript as IMemoryView<TArray> where TArray informs of the underlying type representing the memory region such as Float64Array for double.
This marks the completion of implementing support for all .NET-JS interop types. TypeShim now officially offers a strict superset of functionality over the 'bare' JSExport Api.
What's Changed
- Remove obsolete jsimport functions by @ArcadeMode in #74
- Span & ArraySegment as MemoryView by @ArcadeMode in #76
Full Changelog: v1.2.0...v1.3.0
v1.2.0
Summary
- Simplified initialization by passing return value from
dotnet.create()directly intoTypeShimInitializer.initialize(...). - Proxy objects now preserve reference equality (identity).
- Memory release of initializer objects is sped up significantly. (Memory benchmarks saw a 20% reduction in memory usage).
- TSExport classes that implement IDisposable will auto dispose their handles when Dispose() is invoked from JS.
What's Changed
- Show tests status on main in readme by @ArcadeMode in #65
- Pass created dotnet runtime directly into initializer by @ArcadeMode in #64
- Proxy object identity by @ArcadeMode in #66
- Initializer JSObject disposal by @ArcadeMode in #71
- Proxy Disposal by @ArcadeMode in #72
- Move code to src dir by @ArcadeMode in #73
Full Changelog: v1.1.1...v1.2.0
v1.1.1
Summary
- Inform through diagnostics about generic classes not being supported. Stop codegen when encountering generic class instead of generating invalid code.
- Fix bug in TS initializer parameter interop transforms for get-only properties
What's Changed
- Generics diagnostics by @ArcadeMode in #61
- Getter only included in initializer codegen by @ArcadeMode in #63
Full Changelog: v1.1.0...v1.1.1
v1.1.0
Summary
- New support for
ActionandFunctypes- Can be used as property types and in object initializers
- Can be used as method params/return types
- Proxies can be passed as parameters and return types in both delegate types
- Initializers can be passed in delegate parameters for auto construction
- Bugfix: corrected conversions for
char? - Denser codegen by relying on fewer temps
- Customized JSObject shim rendering to reduce unnecessary codegen output
Stability improvements
To supplement the existing unit tests, E2E testing has been introduced for deeper validation of TypeShim. Including runtime behavior of various types and scenarios on both NodeJS and Browser runtimes.
What's Changed
- E2E tests by @ArcadeMode in #55
- Support for Delegates by @ArcadeMode in #56
Full Changelog: v1.0.2...v1.1.0
v1.0.2
Summary
- Initializer property type support supplemented to match properties and methods
- No nullability warnings in generated C# classes
- Null values in non-nullable initializer properties throw exceptions with meaningful messages
- Auto convert c# char from js number to js string
What's Changed
- Fix void Task property by @ArcadeMode in #52
- Nullability warning & errors + Fixes for certain property types by @ArcadeMode in #51
- Shims for C# char as TS string by @ArcadeMode in #53
Full Changelog: v1.0.1...v1.0.2
v1.0.1
What's Changed
- Fixed bug where using JSObject would fail code gen
- Fixed Roslyn AnalyzerReleases md's
Full Changelog: v1.0.0...v1.0.1
v1.0.0
What's Changed
- New TypeShimInitializer
- type support for nullable reference types, arrays and tasks.
- Real static members in TypeScript
- Removed TSModule, statics are now supported with TSExport
- Callable C# constructors in TypeScript
- Introduced Initializer object for constructors
- Initializer can conditionally be passed as method parameters and be received as initialized class instances in C#
- Sample project extension by @ArcadeMode in #37
- Proxies and snapshots by @ArcadeMode in #38
- Full type support for snapshots by @ArcadeMode in #41
- Static classes+members, constructors by @ArcadeMode in #42
- Drop proxy name from generated TS Api by @ArcadeMode in #50
- Update README.md by @ArcadeMode in #39
Full Changelog: v0.9.0...v1.0.0
v0.9.0
What's Changed
First working version with core features like
- TSExport / TSModule attribute based interop facade generation
- Instance members in TypeScript
- Properties in TypeScript
- Extended types and most .NET interop types supported
- First Analyzers
Gathering feedback for 1.0.0
Full Changelog: https://github.com/ArcadeMode/TypeShim/commits/v0.9.0