← Previous revision | Revision as of 17:15, 4 July 2025 | ||
Line 257: | Line 257: | ||
// Now make a list item for each template that is not inside a <ref> tag |
// Now make a list item for each template that is not inside a <ref> tag |
||
// First remove the references from the wikitext to avoid matching templates inside them |
// First replace the references from the wikitext to avoid matching templates inside them |
||
for ( const reference of references ) { |
for ( const reference of references ) { |
||
wikitext = wikitext.replace( reference.wikitext, '' ); |
const dummy = '@'.repeat( reference.wikitext.length ); |
||
wikitext = wikitext.replace( reference.wikitext, dummy ); |
|||
} |
} |
||
const templates = ProveIt.getTemplates( wikitext ); |
const templates = ProveIt.getTemplates( wikitext ); |