Shared types as attributes of Y.XmlText or Y.XmlElement?

Hello, I’m wondering if shared types (X.Map, etc) are supported as attributes of Y.XmlText or Y.XmlElement. The Typescript typing doesn’t seem to support, but some early tests seem to indicate that it mostly work. Is it a bug in the typing or part of Yjs’ design ?

It looks it doesn’t work well when encoded as a binary update and applied to a new document (Shared types in XmlText/XmlElement attributes after applyUpdates · Issue #527 · yjs/yjs · GitHub).