chrome/forlater.js (view raw)
1function saveForLater(info, tab) {
2 const tabURL = tab.url
3 const mailto = `mailto:save@forlater.email?&body=${tabURL}`
4 chrome.tabs.update({
5 url: mailto,
6 })
7}
8
9chrome.action.onClicked.addListener(saveForLater)
10chrome.contextMenus.create({
11 'title': "Send page to forlater",
12 'contexts': ['all'],
13 'id': 'save forlater menu'
14})
15chrome.contextMenus.onClicked.addListener(saveForLater)