Compare commits
1 commit
u/master
...
u/comishq-
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c215ffc87c |
1 changed files with 15 additions and 0 deletions
15
comicshq.pack.individual.links.user.js
Normal file
15
comicshq.pack.individual.links.user.js
Normal file
|
|
@ -0,0 +1,15 @@
|
||||||
|
// https://thecomicshq.com/comics/weekly-packs/weekly-comic-checklist-9-12-18/
|
||||||
|
|
||||||
|
document.querySelectorAll('.listing-item a').forEach(function (link) {
|
||||||
|
fetch(link.attributes.href.value)
|
||||||
|
.then(res => res.text())
|
||||||
|
.then(function (text) {
|
||||||
|
link.parentElement.appendChild(document.createElement('br'));
|
||||||
|
|
||||||
|
let dom = (new DOMParser()).parseFromString(text, "text/html");
|
||||||
|
let links = dom.querySelectorAll('.td-post-content a.su-button')
|
||||||
|
let importLinks = [...links].map(node => document.importNode(node, true));
|
||||||
|
importLinks.forEach(node => link.parentElement.appendChild(node));
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue