MCPcopy Create free account
hub / github.com/DavidWells/analytics / renderArgWithDoxxx

Function renderArgWithDoxxx

scripts/docs.js:837–858  ·  view source on GitHub ↗
(tag)

Source from the content-addressed store, hash-verified

835
836
837function renderArgWithDoxxx(tag) {
838 const optionalText = (tag.name.match(/^\[/)) ? '(optional) ' : ''
839 if (tag.name === '[data]') {
840 // console.log('tag', tag)
841 }
842 let typesDescription = tag.types.join('|')
843 if (tag.types.includes('GENERIC')) {
844 console.log('tag', tag)
845 console.log(tag.typesDescription)
846 }
847 // Remove link from description
848 // if (tag.typesDescription.match((/<a href/))) {
849 // // console.log('tag.typesDescription', tag.typesDescription)
850 // // console.log('tag.types[0]', tag.types[0])
851 // const realLink = SRC_LINKS[tag.types[0]]
852 // // console.log('realLink', realLink)
853 // if (realLink) {
854 // typesDescription = tag.typesDescription.replace(/href="(.*?)"/, `href="${realLink}"`)
855 // }
856 // }
857 return `- **${tag.name}** ${optionalText}${typesDescription} ${tag.description}`
858}
859
860function renderExample(example) {
861 return `**Example**

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected