i have a code like this
index.js
var content = ['a', 'b', 'c', 'f'];
var $body = $(document.body);
var c = '';
for (var i = 0; i < content.length; i++) {
c += '<div>' + content[i] + '</div>';
}
$body.append(c);
index.html
<html>
<head>
<script src="index.js"></script>
</head>
<body>
</body>
can I automate this process? And Build a index.html with contents?