prpldeprecated

HTML-based static site generator implementing the PRPL pattern.

Usage no npm install needed!

<script type="module">
  import prpl from 'https://cdn.skypack.dev/prpl';
</script>

README

PRPL

HTML-based static site generator implementing the PRPL pattern.

Why

  • No JavaScript required
  • No bundlers or config files
  • No underlying framework (e.g. React, Vue, Angular)
  • Standards based
  • Very, very fast

Install

npm init prpl

Usage

Use a <prpl> element to interpolate content in any HTML file.

Given this HTML file,

<!DOCTYPE html>
<prpl type="page" src="content/notes">
  <head></head>
  <body>
    <main>
      <h1>[title]</h1>
      [body]
    </main>
  </body>
</prpl>

and a markdown file with some metadata,

<!--
title: Hello world!
slug: /notes/my-first-note
date: 2020-11-26
description: This is my first note
categories: Misc
-->

This is my first note

the output is:

<!DOCTYPE html>
<head></head>
<body>
  <main>
    <h1>Hello World!</h1>
    <p>This is my first note</p>
  </main>
</body>