The export to HTML functionality in Confluence Server references the JavaScript source that display the draw.io diagram(s) from the public Internet.


If you do not wish to load that JavaScript, you can reference a version of the JavaScript that you host, instead.


First, clone the Github repo or copy the file needed, viewer.min.js from https://github.com/jgraph/drawio/tree/master/src/main/webapp/js


Host that file somewhere viewers of the web pages containing the embedded HTML page can access it, record the URL to that viewer.min.js, we will use the published Github link, https://jgraph.github.io/drawio//src/main/webapp/js/viewer.min.js.


Go to the plugin configuration page in your Confluence instance, https://BASE_URL/admin/drawioConfig.action.


Click the "Add-on configuration" tab.


Add the key/value:


viewerurl=https://jgraph.github.io/drawio//src/main/webapp/js/viewer.min.js


To the server configuration dialog, on a new line if there is existing configuration. Replace the URL with the URL to your hosted version of the file.


Click "Save changes".