diff options
| author | Philipp Tanlak <philipp.tanlak@gmail.com> | 2025-01-10 13:09:50 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-01-10 13:09:50 +0100 |
| commit | 40e02d5d28e59dbeb6134afdce12536c602e6aa5 (patch) | |
| tree | 24c84c4084cf72e552804397eecc9f5bb3c2d4be /examples | |
| parent | bf99c233a18c3165e0d4d251b41224e5bc6eb93d (diff) | |
Implement manual following (#82)
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/hackernews_manual_follow.js | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/examples/hackernews_manual_follow.js b/examples/hackernews_manual_follow.js new file mode 100644 index 0000000..16e7bee --- /dev/null +++ b/examples/hackernews_manual_follow.js @@ -0,0 +1,13 @@ +export const config = { + url: "https://news.ycombinator.com/", + depth: 2, + follow: [], +}; + +export default function({ url, doc, follow }) { + const next = doc.find(".morelink").attr("href"); + + follow(next); + + return { url, next }; +} |