@@ -29,6 +29,7 @@ function loadNodeContentSync(fileNode) { | |||
let newContent = cutSonarCloudContent(content); | |||
newContent = removeRemainingContentTags(newContent); | |||
newContent = handleIncludes(newContent, fileNode); | |||
newContent = replaceInstanceTag(newContent); | |||
return newContent; | |||
} | |||
@@ -76,6 +77,10 @@ function handleIncludes(content, fileNode) { | |||
}); | |||
} | |||
function replaceInstanceTag(content) { | |||
return content.replace(/{instance}/gi, 'SonarQube'); | |||
} | |||
exports.createFilePath = createFilePath; | |||
exports.createRemoteFileNode = createRemoteFileNode; | |||
exports.loadNodeContent = loadNodeContent; |
@@ -71,7 +71,6 @@ export default class Page extends React.PureComponent<Props> { | |||
htmlPageContent = createAnchorForHeadings(htmlPageContent, realHeadingsList); | |||
htmlPageContent = replaceDynamicLinks(htmlPageContent); | |||
htmlPageContent = replaceImageLinks(htmlPageContent); | |||
htmlPageContent = replaceInstanceTag(htmlPageContent); | |||
return ( | |||
<> | |||
@@ -126,10 +125,6 @@ export const query = graphql` | |||
} | |||
`; | |||
function replaceInstanceTag(content: string) { | |||
return content.replace(/{instance}/gi, 'SonarQube'); | |||
} | |||
function replaceImageLinks(content: string) { | |||
const version = process.env.GATSBY_DOCS_VERSION || ''; | |||
if (version !== '') { |