Files: d410e696e202f0fa3b384dfa76ad876acb28868b / lib / channel / html / link.js
259 bytesRaw
1 | const h = require('mutant/h') |
2 | const normalizeChannel = require('ssb-ref').normalizeChannel |
3 | |
4 | module.exports = function (channel, text = null) { |
5 | const ref = `#${normalizeChannel(channel)}` |
6 | return h('a ChannelLink', { href: ref, title: ref }, text || ref) |
7 | } |
8 |
Built with git-ssb-web