hamlet-js

Watch a folder for haml file changes and generate html files

Usage no npm install needed!

<script type="module">
  import hamletJs from 'https://cdn.skypack.dev/hamlet-js';
</script>

README

Hamlet

Watch a directory for haml file changes and auto generate html files.

npm install hamlet-js

Then set it to watch a directory:

cd directory-with-haml-files
hamlet -v

Handling Layouts

If the watcher finds a file called layout.haml it will use it as a wrapper for any other files in the directory. Each non-layout template will be injected into the view wherever a = yield is found.