Thanks a lot. One more topic is that, in some cases the properties are predefined in the object definition: Selection* {.importc.} = ref object ## see `docs<https://developer.mozilla.org/en-US/docs/Web/API/Selection>`_ anchorNode*: Node anchorOffset*: int focusNode*: Node focusOffset*: int isCollapsed*: bool rangeCount*: int `type`*: cstring Run
I think this is desirable in particular when you are reading the code. But I think this is generating problems in my code. When I create an instance, those properties not assigned get a null in the JS code and the library that I am wrapping gets confused. Is there a way to tell not to export the properties with no value assigned?