Don't put your template in the www/ directory:
https://shiny.rstudio.com/articles/templates.html
To use an HTML template for the UI, first create an HTML file in your app directory, at the same level as the ui.R , server.R , or app.R files (not in a www/ subdirectory). Here’s an example template for a complete web page,
I can see in the console that the external JS and CSS files are not loaded. Did you include the headcontent() tag in your html file like below:
<!DOCTYPE html>
<html>
<head>
<script src="//d3js.org/d3.v3.min.js" charset="utf-8"></script>
{{ suppressDependencies("d3") }}
{{ headContent() }}
</head>
...
</html>