Announcing Broca and Brio

62 views
Skip to first unread message

Matt Brennan

unread,
Aug 9, 2014, 7:45:16 AM8/9/14
to lives...@googlegroups.com
Broca is a really tiny frontmatter parser and extractor. It's mostly just a wrapper around CSON, and it weighs in at 450 bytes unminified.

Brio extends Broca to support Jekyll-style layouts. It doesn't do any IO, you just give it a templater (Handlebars would suffice), a tree of templates (with frontmatter), a dotted path to a template, and a data object.

Hope they can be of use to someone :)

Piotr Klibert

unread,
Aug 9, 2014, 9:12:29 PM8/9/14
to lives...@googlegroups.com
Links to Github, for the lazy:


Why pretend that JS has multiline strings? Doesn't it make examples invalid in every (JS, LS, Coffee) language? I think writing them in proper JS or LS would be better.

Matt Brennan

unread,
Aug 10, 2014, 4:10:46 AM8/10/14
to lives...@googlegroups.com
Whoops, sorry I forgot the links. The syntax I used in the examples is valid ES6. I wanted to avoid syntactic noise. The strings aren't the most important parts of the examples.

Piotr Klibert

unread,
Aug 11, 2014, 5:34:56 AM8/11/14
to lives...@googlegroups.com
The syntax I used in the examples is valid ES6. 

Wow, I didn't know about this, that's cool. From what I see it's supported in latest FF - seriously nice.
Reply all
Reply to author
Forward
0 new messages