git ssb

3+

arj / patchbook



Tree: bd040e587da9831443f9a4542c1a318f354a7487

Files: bd040e587da9831443f9a4542c1a318f354a7487 / book / html / authors.js

480 bytesRaw
1const nest = require('depnest')
2const { h, when } = require('mutant')
3
4exports.needs = nest({
5 'blob.sync.url': 'first'
6})
7
8exports.gives = nest(
9 'book.html.authors'
10)
11
12exports.create = (api) => {
13 return nest('book.html.authors', authors)
14 function authors ({authors, isEditing, onUpdate}) {
15 return h('section.authors',
16 when(isEditing,
17 h('input', {'ev-input': e => onUpdate(e.target.value), value: authors}),
18 h('span', authors)
19 )
20 )
21 }
22}
23

Built with git-ssb-web