With the newest update to Word (1611) dialogs with TinyMCE causes error 12003: Invalid URL Syntax.
According to Use the Dialog API the cause is
The dialog box was directed to a URL with the HTTP protocol. HTTPS is required.
Simple example is to put below code in a dialog (oddly enough it works in a panel).
Updated code
<!DOCTYPE html>
<html>
<head>
<title>Office.js with TinyMCE</title>
<meta charset="utf-8" />
<script src="https://appsforoffice.microsoft.com/lib/1.1/hosted/office.js" type="text/javascript"></script>
<script src="https://code.jquery.com/jquery-1.12.4.min.js"></script>
<script src="https://cdn.tinymce.com/4/tinymce.min.js"></script>
<script type="text/javascript">
(function () {
"use strict";
// The initialize function must be run each time a new page is loaded.
Office.initialize = function (reason) {
$(document).ready(function () {
tinymce.init({ selector: 'textarea' });
});
};
})();
</script>
</head>
<body>
<textarea></textarea>
</body>
</html>
Edit1: This is only a problem on Windows. On Mac it works fine.
Edit2: The code for opening the dialog
var url = 'https://' + location.host + '/dialog.html';
console.log('url: ' + url); // url: https://localhost:44341/dialog.html
Office.context.ui.displayDialogAsync(url, { height: 30, width: 20 });