MCPcopy Create free account
hub / github.com/hackmdio/codimd / anchorForId

Function anchorForId

public/js/extra.js:1038–1045  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1036}
1037
1038const anchorForId = id => {
1039 const anchor = document.createElement('a')
1040 anchor.className = 'anchor hidden-xs'
1041 anchor.href = `#${id}`
1042 anchor.innerHTML = '<i class="fa fa-link"></i>'
1043 anchor.title = id
1044 return anchor
1045}
1046
1047const createHeaderId = (headerContent, headerIds = null) => {
1048 // to escape characters not allow in css and humanize

Callers 1

linkifyAnchorsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected