Vega and Vega-lite are both available as npm packages. That means that you can use uibuilder to serve the code.
Also, it is best practice to avoid using the scheme, host and port in your URL's in the HTML file. Instead use the relative URLs so that things don't break if, for example, you access the page from a different device. At the moment, your URL's will only work when the browser is on the same device as the server.