simple-html-index
A tiny through stream that returns a bare-bones HTML5 template with an optional <title>
in the head and <script>
entry-point in the body.
Example
In html.js
var html = require('simple-html-index')
html({ title: 'hello', entry: 'bundle.js' })
.pipe(process.stdout)
Now run node html.js > index.html
and you would end up with a file that looks like this: (after formatting)
<!doctype html>
<head>
<title>hello</title>
<meta charset="utf-8">
</head>
<body>
<script src="bundle.js"></script>
</body>
</html>
Usage
License
MIT, see LICENSE.md for details.