Skip to content

Commit 8e81728

Browse files
committed
fix(remark): Allow parameterless %%RESIST%% directive
1 parent a732814 commit 8e81728

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/remark/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ export default function remarkResistogram(options: { dataDir?: string, files?: a
9999
for (let i = nodesToProcess.length - 1; i >= 0; i--) {
100100
const { node, index, parent } = nodesToProcess[i];
101101
const text = toString(node);
102-
const regex = /%%RESIST\s+([^%]*)%%/;
102+
const regex = /%%RESIST\s*([^%]*)%%/g;
103103
const match = text.match(regex);
104104

105105
if (!match || match.index === undefined) continue;

0 commit comments

Comments
 (0)