- well-formed markup
All the markup inserted through the
innerHTMLproperty must be well-formed. Otherwise, everything fails silently.
- characters and entities
All characters must be mapped to their corresponding XML entities. You cannot insert junk content into a DOMString without seeing an error. Further, you must be aware of the encoding used on your pages and code accordingly.
jQuery and other libraries work well, though. That's because they were designed for returning standard content.