How to use the dmd/helpers/helpers.inlineLinks function in dmd

To help you get started, we’ve selected a few dmd examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github electron-userland / electron-builder / scripts / renderer / src / properties.ts View on Github external
function renderMemberListDescription(text: string, indent: string) {
  let data: string = dmdHelper.inlineLinks(text)
    .replace(/<br>/g, "\n")
    .replace(/\n/g, "\n" + indent)
    .replace(new RegExp("\\*{2}\\\\/", "g"), "**/")
    .trim()
  if (data.includes("\n")) {
    // mkdocs requires newline for multi line list item text (otherwise next item on the same line and rendered as list item)
    data += "\n"
  }
  return data
}
github electron-userland / electron-builder / scripts / jsdoc / helpers.js View on Github external
function renderMemberListDescription(text, indent) {
  return dmdHelper.inlineLinks(text)
    .replace(/<br>/g, "\n")
    .replace(/\n/g, "\n" + indent)
    .replace(new RegExp("\\*{2}\\\\/", "g"), "**/")
}