Consider a IJSTypeValidator interface, where implementors can implement custom interop that validates the JS type is of the expected type. This will ensure if a type is incorrectly wrapped, then it will fail-early-fail-fast by checking the JS type upon wrapping/instantiation. Rather than where a runtime error would occur later during interaction with the type's members, and likely provide less than informative errors such as undefined.
Consider a IJSTypeValidator interface, where implementors can implement custom interop that validates the JS type is of the expected type. This will ensure if a type is incorrectly wrapped, then it will fail-early-fail-fast by checking the JS type upon wrapping/instantiation. Rather than where a runtime error would occur later during interaction with the type's members, and likely provide less than informative errors such as
undefined.