cactus icon indicating copy to clipboard operation
cactus copied to clipboard

Support more General Templating

Open leostera opened this issue 5 years ago • 0 comments

If site files supported rules like:

(page
   index.md
   (with-generator Index.re))

Then perhaps we can define Index.re to be:

open Cactus;

include Cactus.Generator.Make({

  let render = (ctx, project, site, page) => {
     /* and here we can transform the Index.md page using Omd */ 
  };

});

This would allow to treat pages as inputs to modules, which can then do really just any amount of side-effects to transform them (including any I/O).

xrefs: #8

leostera avatar Feb 04 '19 15:02 leostera