deally, this function would use @ViewBuilder to avoid type erasure with AnyView, which would improve type safety and allow for more natural SwiftUI composition.
However, applying modifiers dynamically based on a dictionary of keys and values currently requires type erasure, since @ViewBuilder expects a static view hierarchy.
https://github.com/0xWDG/DynamicUI/blob/main/Sources/DynamicUI/Extensions/View.modifiers.swift#L17-L112