generated at
scrapbox-processor
index.js
export const addScrapboxProcessorButton = ({title, image, processors}) => { scrapbox.PageMenu.addMenu({ title, image, onClick: async () => { try { let text = scrapbox.Page.lines.map((line) => line.text).join("\n"); for (const processor of processors) { text = (await processor.process({text})).text; } } catch(exception) { alert(exception.message); } }, }); };