Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
scrapbox.PopupMenu.addButton({
title: 'code',
onClick: text => {
return 'code:script\n' + text.split(/\n/).map(line => '\t' + line).join('\n');
}
});
scrapbox.PopupMenu.addButton({
title: 'table',
onClick: text => {
return 'table:table\n' +
text.split(/\n/).map(line => '\t' + line.split(/,/).join("\t") ).join('\n');
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment