nitro-ui-swift-cxx
Installation
SKILL.md
- Generated calls always use
SwiftConverter<CppType, SwiftType>.SwiftType.requiresExplicitSwiftTargetcontrols specialization declarations only; preserve default mappings for handwritten C++. - For Array/Optional, implement the explicit specialization directly and delegate the default specialization to it. Use
CppElementType/SwiftElementType; explain default-selection convenience consistently across equivalent specializations. - Adapt callback signatures through the existing private native/JS alternatives and converter friendship. Do not add
AdaptedCallbackstate just to record adaptation. - Preserve umbrella ordering: C++ prerequisites, dependency module umbrellas, local generated Swift definitions, then converters. Swift-facing public headers must not include their own
-Swift.hor the private implementation umbrella. - Foreign HybridObject converters come from their owning module. Shared runtime converters belong in
nitro-modules-swift-bridge; generated module converters belong in that module's SwiftBridge target. - Collect Swift imports from both API types and wrapped types. Use
getSwiftImports()andgetImportsCode()for access levels and promotion; avoid blanket@usableFromInlinefixes. - Optional dictionary cursor slots support types without default initializers. Do not lose that support for simpler iteration; Swift
.get()can create owned values with allocation or retain/release costs. - In a PR stack, regenerate and commit affected bridge files in each atomic PR alongside its source changes. Keep each PR buildable; do not collect generated output in a final PR.