I'm not sure, but it's easy to test on the mojoPortal demo site. Create a new HTML instance on a page and add your HTML and JavaScript in the editor's HTML view. Sometimes the editor can strip out some of the formatting or add paragraph tags. If you find this interfering with your code, go into the module settings and uncheck the "Use WYSIWYG Editor" box. Then you'll just be entering raw HTML/JavaScript in a text box without any editor processing.
Jamie