feedscout 1.4.0 → 1.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +12 -17
- package/dist/blogrolls/defaults.cjs +1 -3
- package/dist/blogrolls/defaults.js +1 -2
- package/dist/blogrolls/extractors.cjs +6 -9
- package/dist/blogrolls/extractors.js +6 -9
- package/dist/blogrolls/index.cjs +6 -9
- package/dist/blogrolls/index.d.cts +1 -1
- package/dist/blogrolls/index.d.ts +1 -1
- package/dist/blogrolls/index.js +1 -4
- package/dist/blogrolls.cjs +4 -5
- package/dist/blogrolls.js +1 -2
- package/dist/common/discover/index.cjs +60 -21
- package/dist/common/discover/index.js +58 -19
- package/dist/common/discover/utils.cjs +30 -9
- package/dist/common/discover/utils.js +28 -8
- package/dist/common/locales.cjs +127 -8
- package/dist/common/locales.js +116 -2
- package/dist/common/types.cjs +10 -0
- package/dist/common/types.d.cts +23 -5
- package/dist/common/types.d.ts +23 -5
- package/dist/common/types.js +10 -0
- package/dist/common/uris/feed/index.cjs +12 -0
- package/dist/common/uris/feed/index.d.cts +6 -0
- package/dist/common/uris/feed/index.d.ts +6 -0
- package/dist/common/uris/feed/index.js +12 -0
- package/dist/common/uris/feed/types.d.cts +9 -0
- package/dist/common/uris/feed/types.d.ts +9 -0
- package/dist/common/uris/guess/index.cjs +2 -4
- package/dist/common/uris/guess/index.d.cts +2 -1
- package/dist/common/uris/guess/index.d.ts +2 -1
- package/dist/common/uris/guess/index.js +1 -3
- package/dist/common/uris/guess/types.d.cts +3 -1
- package/dist/common/uris/guess/types.d.ts +3 -1
- package/dist/common/uris/guess/utils.cjs +5 -4
- package/dist/common/uris/guess/utils.d.cts +3 -1
- package/dist/common/uris/guess/utils.d.ts +3 -1
- package/dist/common/uris/guess/utils.js +5 -3
- package/dist/common/uris/headers/index.cjs +2 -4
- package/dist/common/uris/headers/index.js +1 -3
- package/dist/common/uris/html/handlers.cjs +2 -4
- package/dist/common/uris/html/handlers.js +1 -3
- package/dist/common/uris/html/index.cjs +2 -4
- package/dist/common/uris/html/index.js +1 -3
- package/dist/common/uris/index.cjs +23 -17
- package/dist/common/uris/index.js +19 -13
- package/dist/common/uris/platform/index.cjs +3 -5
- package/dist/common/uris/platform/index.d.cts +7 -0
- package/dist/common/uris/platform/index.d.ts +7 -0
- package/dist/common/uris/platform/index.js +3 -4
- package/dist/common/uris/platform/types.d.cts +4 -2
- package/dist/common/uris/platform/types.d.ts +4 -2
- package/dist/common/utils.cjs +25 -8
- package/dist/common/utils.d.cts +2 -2
- package/dist/common/utils.d.ts +2 -2
- package/dist/common/utils.js +23 -7
- package/dist/favicons/defaults.cjs +60 -0
- package/dist/favicons/defaults.d.cts +18 -0
- package/dist/favicons/defaults.d.ts +18 -0
- package/dist/favicons/defaults.js +53 -0
- package/dist/favicons/extractors.cjs +13 -0
- package/dist/favicons/extractors.d.cts +7 -0
- package/dist/favicons/extractors.d.ts +7 -0
- package/dist/favicons/extractors.js +13 -0
- package/dist/favicons/index.cjs +29 -0
- package/dist/favicons/index.d.cts +7 -0
- package/dist/favicons/index.d.ts +7 -0
- package/dist/favicons/index.js +29 -0
- package/dist/favicons/platform/handlers/bluesky.cjs +27 -0
- package/dist/favicons/platform/handlers/bluesky.js +27 -0
- package/dist/favicons/platform/handlers/codeberg.cjs +18 -0
- package/dist/favicons/platform/handlers/codeberg.js +18 -0
- package/dist/favicons/platform/handlers/deviantart.cjs +29 -0
- package/dist/favicons/platform/handlers/deviantart.js +29 -0
- package/dist/favicons/platform/handlers/github.cjs +18 -0
- package/dist/favicons/platform/handlers/github.js +18 -0
- package/dist/favicons/platform/handlers/githubGist.cjs +18 -0
- package/dist/favicons/platform/handlers/githubGist.js +18 -0
- package/dist/favicons/platform/handlers/lobsters.cjs +21 -0
- package/dist/favicons/platform/handlers/lobsters.js +21 -0
- package/dist/favicons/platform/handlers/mastodon.cjs +36 -0
- package/dist/favicons/platform/handlers/mastodon.js +34 -0
- package/dist/favicons/platform/handlers/reddit.cjs +41 -0
- package/dist/favicons/platform/handlers/reddit.js +41 -0
- package/dist/favicons/platform/handlers/sourceforge.cjs +21 -0
- package/dist/favicons/platform/handlers/sourceforge.js +21 -0
- package/dist/favicons/platform/handlers/tumblr.cjs +16 -0
- package/dist/favicons/platform/handlers/tumblr.js +16 -0
- package/dist/favicons/types.d.cts +4 -0
- package/dist/favicons/types.d.ts +4 -0
- package/dist/favicons.cjs +12 -0
- package/dist/favicons.d.cts +4 -0
- package/dist/favicons.d.ts +4 -0
- package/dist/favicons.js +3 -0
- package/dist/feeds/defaults.cjs +66 -37
- package/dist/feeds/defaults.d.cts +2 -2
- package/dist/feeds/defaults.d.ts +2 -2
- package/dist/feeds/defaults.js +52 -23
- package/dist/feeds/extractors.cjs +1 -3
- package/dist/feeds/extractors.js +1 -3
- package/dist/feeds/index.cjs +6 -8
- package/dist/feeds/index.d.cts +1 -1
- package/dist/feeds/index.d.ts +1 -1
- package/dist/feeds/index.js +1 -3
- package/dist/feeds/platform/handlers/behance.cjs +10 -6
- package/dist/feeds/platform/handlers/behance.js +10 -6
- package/dist/feeds/platform/handlers/blogspot.cjs +19 -8
- package/dist/feeds/platform/handlers/blogspot.js +19 -7
- package/dist/feeds/platform/handlers/bluesky.cjs +7 -6
- package/dist/feeds/platform/handlers/bluesky.js +7 -6
- package/dist/feeds/platform/handlers/codeberg.cjs +69 -0
- package/dist/feeds/platform/handlers/codeberg.js +67 -0
- package/dist/feeds/platform/handlers/csdn.cjs +19 -0
- package/dist/feeds/platform/handlers/csdn.js +19 -0
- package/dist/feeds/platform/handlers/dailymotion.cjs +10 -6
- package/dist/feeds/platform/handlers/dailymotion.js +10 -6
- package/dist/feeds/platform/handlers/deviantart.cjs +20 -8
- package/dist/feeds/platform/handlers/deviantart.js +18 -8
- package/dist/feeds/platform/handlers/devto.cjs +10 -6
- package/dist/feeds/platform/handlers/devto.js +10 -6
- package/dist/feeds/platform/handlers/douban.cjs +54 -0
- package/dist/feeds/platform/handlers/douban.js +54 -0
- package/dist/feeds/platform/handlers/github.cjs +37 -16
- package/dist/feeds/platform/handlers/github.js +35 -16
- package/dist/feeds/platform/handlers/githubGist.cjs +17 -17
- package/dist/feeds/platform/handlers/githubGist.js +15 -17
- package/dist/feeds/platform/handlers/gitlab.cjs +18 -8
- package/dist/feeds/platform/handlers/gitlab.js +18 -8
- package/dist/feeds/platform/handlers/goodreads.cjs +39 -0
- package/dist/feeds/platform/handlers/goodreads.js +39 -0
- package/dist/feeds/platform/handlers/hashnode.cjs +16 -0
- package/dist/feeds/platform/handlers/hashnode.js +16 -0
- package/dist/feeds/platform/handlers/hatenablog.cjs +53 -0
- package/dist/feeds/platform/handlers/hatenablog.js +53 -0
- package/dist/feeds/platform/handlers/itchio.cjs +88 -0
- package/dist/feeds/platform/handlers/itchio.js +88 -0
- package/dist/feeds/platform/handlers/kickstarter.cjs +10 -6
- package/dist/feeds/platform/handlers/kickstarter.js +10 -6
- package/dist/feeds/platform/handlers/letterboxd.cjs +42 -0
- package/dist/feeds/platform/handlers/letterboxd.js +42 -0
- package/dist/feeds/platform/handlers/lobsters.cjs +35 -12
- package/dist/feeds/platform/handlers/lobsters.js +34 -12
- package/dist/feeds/platform/handlers/mastodon.cjs +40 -0
- package/dist/feeds/platform/handlers/mastodon.js +40 -0
- package/dist/feeds/platform/handlers/medium.cjs +26 -10
- package/dist/feeds/platform/handlers/medium.js +26 -10
- package/dist/feeds/platform/handlers/paragraph.cjs +21 -0
- package/dist/feeds/platform/handlers/paragraph.js +21 -0
- package/dist/feeds/platform/handlers/pinterest.cjs +6 -10
- package/dist/feeds/platform/handlers/pinterest.js +6 -10
- package/dist/feeds/platform/handlers/producthunt.cjs +14 -7
- package/dist/feeds/platform/handlers/producthunt.js +14 -7
- package/dist/feeds/platform/handlers/reddit.cjs +35 -12
- package/dist/feeds/platform/handlers/reddit.js +34 -12
- package/dist/feeds/platform/handlers/soundcloud.cjs +6 -5
- package/dist/feeds/platform/handlers/soundcloud.js +6 -5
- package/dist/feeds/platform/handlers/sourceforge.cjs +20 -0
- package/dist/feeds/platform/handlers/sourceforge.js +19 -0
- package/dist/feeds/platform/handlers/stackExchange.cjs +37 -0
- package/dist/feeds/platform/handlers/stackExchange.js +37 -0
- package/dist/feeds/platform/handlers/steam.cjs +26 -0
- package/dist/feeds/platform/handlers/steam.js +26 -0
- package/dist/feeds/platform/handlers/substack.cjs +6 -5
- package/dist/feeds/platform/handlers/substack.js +6 -5
- package/dist/feeds/platform/handlers/tumblr.cjs +13 -7
- package/dist/feeds/platform/handlers/tumblr.js +12 -7
- package/dist/feeds/platform/handlers/v2ex.cjs +33 -0
- package/dist/feeds/platform/handlers/v2ex.js +33 -0
- package/dist/feeds/platform/handlers/vimeo.cjs +68 -0
- package/dist/feeds/platform/handlers/vimeo.js +68 -0
- package/dist/feeds/platform/handlers/wordpress.cjs +46 -12
- package/dist/feeds/platform/handlers/wordpress.js +46 -12
- package/dist/feeds/platform/handlers/wpengine.cjs +10 -0
- package/dist/feeds/platform/handlers/wpengine.js +11 -0
- package/dist/feeds/platform/handlers/ximalaya.cjs +19 -0
- package/dist/feeds/platform/handlers/ximalaya.js +19 -0
- package/dist/feeds/platform/handlers/youtube.cjs +35 -13
- package/dist/feeds/platform/handlers/youtube.js +35 -13
- package/dist/feeds.cjs +4 -5
- package/dist/feeds.js +1 -2
- package/dist/hubs/discover/index.cjs +7 -9
- package/dist/hubs/discover/index.js +1 -3
- package/dist/hubs/discover/utils.cjs +1 -3
- package/dist/hubs/discover/utils.js +1 -2
- package/dist/hubs/feed/index.cjs +1 -3
- package/dist/hubs/feed/index.js +1 -3
- package/dist/hubs/headers/index.cjs +3 -5
- package/dist/hubs/headers/index.js +1 -3
- package/dist/hubs/html/index.cjs +3 -5
- package/dist/hubs/html/index.js +1 -3
- package/dist/hubs.js +1 -1
- package/dist/index.cjs +8 -7
- package/dist/index.d.cts +3 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +2 -2
- package/dist/methods.cjs +13 -10
- package/dist/methods.d.cts +3 -1
- package/dist/methods.d.ts +3 -1
- package/dist/methods.js +3 -2
- package/dist/utils.cjs +3 -4
- package/dist/utils.js +1 -2
- package/package.json +15 -5
package/dist/feeds/defaults.cjs
CHANGED
|
@@ -1,24 +1,40 @@
|
|
|
1
|
-
const
|
|
2
|
-
const
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
const
|
|
12
|
-
const
|
|
13
|
-
const
|
|
14
|
-
const
|
|
15
|
-
const
|
|
16
|
-
const
|
|
17
|
-
const
|
|
18
|
-
const
|
|
19
|
-
const
|
|
20
|
-
const
|
|
21
|
-
|
|
1
|
+
const require_codeberg = require("./platform/handlers/codeberg.cjs");
|
|
2
|
+
const require_deviantart = require("./platform/handlers/deviantart.cjs");
|
|
3
|
+
const require_github = require("./platform/handlers/github.cjs");
|
|
4
|
+
const require_githubGist = require("./platform/handlers/githubGist.cjs");
|
|
5
|
+
const require_lobsters = require("./platform/handlers/lobsters.cjs");
|
|
6
|
+
const require_reddit = require("./platform/handlers/reddit.cjs");
|
|
7
|
+
const require_sourceforge = require("./platform/handlers/sourceforge.cjs");
|
|
8
|
+
const require_tumblr = require("./platform/handlers/tumblr.cjs");
|
|
9
|
+
const require_behance = require("./platform/handlers/behance.cjs");
|
|
10
|
+
const require_blogspot = require("./platform/handlers/blogspot.cjs");
|
|
11
|
+
const require_bluesky = require("./platform/handlers/bluesky.cjs");
|
|
12
|
+
const require_csdn = require("./platform/handlers/csdn.cjs");
|
|
13
|
+
const require_dailymotion = require("./platform/handlers/dailymotion.cjs");
|
|
14
|
+
const require_devto = require("./platform/handlers/devto.cjs");
|
|
15
|
+
const require_douban = require("./platform/handlers/douban.cjs");
|
|
16
|
+
const require_gitlab = require("./platform/handlers/gitlab.cjs");
|
|
17
|
+
const require_goodreads = require("./platform/handlers/goodreads.cjs");
|
|
18
|
+
const require_hashnode = require("./platform/handlers/hashnode.cjs");
|
|
19
|
+
const require_hatenablog = require("./platform/handlers/hatenablog.cjs");
|
|
20
|
+
const require_itchio = require("./platform/handlers/itchio.cjs");
|
|
21
|
+
const require_kickstarter = require("./platform/handlers/kickstarter.cjs");
|
|
22
|
+
const require_letterboxd = require("./platform/handlers/letterboxd.cjs");
|
|
23
|
+
const require_mastodon = require("./platform/handlers/mastodon.cjs");
|
|
24
|
+
const require_medium = require("./platform/handlers/medium.cjs");
|
|
25
|
+
const require_paragraph = require("./platform/handlers/paragraph.cjs");
|
|
26
|
+
const require_pinterest = require("./platform/handlers/pinterest.cjs");
|
|
27
|
+
const require_producthunt = require("./platform/handlers/producthunt.cjs");
|
|
28
|
+
const require_soundcloud = require("./platform/handlers/soundcloud.cjs");
|
|
29
|
+
const require_stackExchange = require("./platform/handlers/stackExchange.cjs");
|
|
30
|
+
const require_steam = require("./platform/handlers/steam.cjs");
|
|
31
|
+
const require_substack = require("./platform/handlers/substack.cjs");
|
|
32
|
+
const require_v2ex = require("./platform/handlers/v2ex.cjs");
|
|
33
|
+
const require_vimeo = require("./platform/handlers/vimeo.cjs");
|
|
34
|
+
const require_wordpress = require("./platform/handlers/wordpress.cjs");
|
|
35
|
+
const require_wpengine = require("./platform/handlers/wpengine.cjs");
|
|
36
|
+
const require_ximalaya = require("./platform/handlers/ximalaya.cjs");
|
|
37
|
+
const require_youtube = require("./platform/handlers/youtube.cjs");
|
|
22
38
|
//#region src/feeds/defaults.ts
|
|
23
39
|
const mimeTypes = [
|
|
24
40
|
"application/rss+xml",
|
|
@@ -59,19 +75,13 @@ const urisComprehensive = [
|
|
|
59
75
|
"/feed.atom",
|
|
60
76
|
"/feed.rss.xml",
|
|
61
77
|
"/feed.atom.xml",
|
|
62
|
-
"/feed/atom/",
|
|
63
|
-
"/feed/rss/",
|
|
64
|
-
"/feed/rss2/",
|
|
65
|
-
"/feed/rdf",
|
|
66
|
-
"/feed/rdf/",
|
|
78
|
+
["/feed/atom/", "?feed=atom"],
|
|
79
|
+
["/feed/rss/", "?feed=rss"],
|
|
80
|
+
["/feed/rss2/", "?feed=rss2"],
|
|
81
|
+
["/feed/rdf", "?feed=rdf"],
|
|
82
|
+
["/feed/rdf/", "?feed=rdf"],
|
|
67
83
|
"/index.rss.xml",
|
|
68
84
|
"/index.atom.xml",
|
|
69
|
-
"?feed=rss",
|
|
70
|
-
"?feed=rss2",
|
|
71
|
-
"?feed=atom",
|
|
72
|
-
"?feed=rdf",
|
|
73
|
-
"?feed=comments-rss2",
|
|
74
|
-
"?feed=comments-atom",
|
|
75
85
|
"?format=rss",
|
|
76
86
|
"?format=atom",
|
|
77
87
|
"?rss=1",
|
|
@@ -81,7 +91,10 @@ const urisComprehensive = [
|
|
|
81
91
|
"/f.rss",
|
|
82
92
|
"/json",
|
|
83
93
|
"/.feed",
|
|
84
|
-
"/comments/feed",
|
|
94
|
+
["/comments/feed", "?feed=comments-rss2"],
|
|
95
|
+
["/comments/feed/rss2/", "?feed=comments-rss2"],
|
|
96
|
+
["/comments/feed/rdf/", "?feed=comments-rdf"],
|
|
97
|
+
["/comments/feed/atom/", "?feed=comments-atom"],
|
|
85
98
|
"/feeds/posts/default",
|
|
86
99
|
"/feeds/posts/default?alt=rss",
|
|
87
100
|
"/feeds/comments/default"
|
|
@@ -102,7 +115,7 @@ const linkSelectors = [{
|
|
|
102
115
|
}, { rel: "feed" }];
|
|
103
116
|
const defaultHtmlOptions = {
|
|
104
117
|
linkSelectors,
|
|
105
|
-
anchorUris: urisComprehensive,
|
|
118
|
+
anchorUris: urisComprehensive.flat(),
|
|
106
119
|
anchorIgnoredUris: ignoredUris,
|
|
107
120
|
anchorLabels
|
|
108
121
|
};
|
|
@@ -112,25 +125,41 @@ const defaultPlatformOptions = { handlers: [
|
|
|
112
125
|
require_behance.behanceHandler,
|
|
113
126
|
require_blogspot.blogspotHandler,
|
|
114
127
|
require_bluesky.blueskyHandler,
|
|
128
|
+
require_csdn.csdnHandler,
|
|
129
|
+
require_codeberg.codebergHandler,
|
|
130
|
+
require_douban.doubanHandler,
|
|
115
131
|
require_deviantart.deviantartHandler,
|
|
116
132
|
require_dailymotion.dailymotionHandler,
|
|
117
133
|
require_devto.devtoHandler,
|
|
134
|
+
require_goodreads.goodreadsHandler,
|
|
118
135
|
require_github.githubHandler,
|
|
136
|
+
require_hashnode.hashnodeHandler,
|
|
137
|
+
require_hatenablog.hatenablogHandler,
|
|
119
138
|
require_githubGist.githubGistHandler,
|
|
120
139
|
require_gitlab.gitlabHandler,
|
|
140
|
+
require_itchio.itchioHandler,
|
|
121
141
|
require_kickstarter.kickstarterHandler,
|
|
142
|
+
require_letterboxd.letterboxdHandler,
|
|
143
|
+
require_lobsters.lobstersHandler,
|
|
144
|
+
require_mastodon.mastodonHandler,
|
|
122
145
|
require_medium.mediumHandler,
|
|
146
|
+
require_paragraph.paragraphHandler,
|
|
123
147
|
require_pinterest.pinterestHandler,
|
|
124
148
|
require_producthunt.producthuntHandler,
|
|
125
|
-
require_lobsters.lobstersHandler,
|
|
126
149
|
require_reddit.redditHandler,
|
|
127
150
|
require_soundcloud.soundcloudHandler,
|
|
151
|
+
require_sourceforge.sourceforgeHandler,
|
|
152
|
+
require_stackExchange.stackExchangeHandler,
|
|
153
|
+
require_steam.steamHandler,
|
|
128
154
|
require_substack.substackHandler,
|
|
129
155
|
require_tumblr.tumblrHandler,
|
|
156
|
+
require_v2ex.v2exHandler,
|
|
157
|
+
require_vimeo.vimeoHandler,
|
|
130
158
|
require_wordpress.wordpressHandler,
|
|
159
|
+
require_wpengine.wpengineHandler,
|
|
160
|
+
require_ximalaya.ximalayaHandler,
|
|
131
161
|
require_youtube.youtubeHandler
|
|
132
162
|
] };
|
|
133
|
-
|
|
134
163
|
//#endregion
|
|
135
164
|
exports.anchorLabels = anchorLabels;
|
|
136
165
|
exports.defaultGuessOptions = defaultGuessOptions;
|
|
@@ -142,4 +171,4 @@ exports.linkSelectors = linkSelectors;
|
|
|
142
171
|
exports.mimeTypes = mimeTypes;
|
|
143
172
|
exports.urisBalanced = urisBalanced;
|
|
144
173
|
exports.urisComprehensive = urisComprehensive;
|
|
145
|
-
exports.urisMinimal = urisMinimal;
|
|
174
|
+
exports.urisMinimal = urisMinimal;
|
|
@@ -2,13 +2,13 @@ import { GuessMethodOptions } from "../common/uris/guess/types.cjs";
|
|
|
2
2
|
import { HeadersMethodOptions } from "../common/uris/headers/types.cjs";
|
|
3
3
|
import { HtmlMethodOptions } from "../common/uris/html/types.cjs";
|
|
4
4
|
import { PlatformMethodOptions } from "../common/uris/platform/types.cjs";
|
|
5
|
-
import { LinkSelector } from "../common/types.cjs";
|
|
5
|
+
import { LinkSelector, UriEntry } from "../common/types.cjs";
|
|
6
6
|
|
|
7
7
|
//#region src/feeds/defaults.d.ts
|
|
8
8
|
declare const mimeTypes: string[];
|
|
9
9
|
declare const urisMinimal: string[];
|
|
10
10
|
declare const urisBalanced: string[];
|
|
11
|
-
declare const urisComprehensive:
|
|
11
|
+
declare const urisComprehensive: Array<UriEntry>;
|
|
12
12
|
declare const ignoredUris: string[];
|
|
13
13
|
declare const anchorLabels: string[];
|
|
14
14
|
declare const linkSelectors: Array<LinkSelector>;
|
package/dist/feeds/defaults.d.ts
CHANGED
|
@@ -2,13 +2,13 @@ import { GuessMethodOptions } from "../common/uris/guess/types.js";
|
|
|
2
2
|
import { HeadersMethodOptions } from "../common/uris/headers/types.js";
|
|
3
3
|
import { HtmlMethodOptions } from "../common/uris/html/types.js";
|
|
4
4
|
import { PlatformMethodOptions } from "../common/uris/platform/types.js";
|
|
5
|
-
import { LinkSelector } from "../common/types.js";
|
|
5
|
+
import { LinkSelector, UriEntry } from "../common/types.js";
|
|
6
6
|
|
|
7
7
|
//#region src/feeds/defaults.d.ts
|
|
8
8
|
declare const mimeTypes: string[];
|
|
9
9
|
declare const urisMinimal: string[];
|
|
10
10
|
declare const urisBalanced: string[];
|
|
11
|
-
declare const urisComprehensive:
|
|
11
|
+
declare const urisComprehensive: Array<UriEntry>;
|
|
12
12
|
declare const ignoredUris: string[];
|
|
13
13
|
declare const anchorLabels: string[];
|
|
14
14
|
declare const linkSelectors: Array<LinkSelector>;
|
package/dist/feeds/defaults.js
CHANGED
|
@@ -1,24 +1,40 @@
|
|
|
1
|
+
import { codebergHandler } from "./platform/handlers/codeberg.js";
|
|
2
|
+
import { deviantartHandler } from "./platform/handlers/deviantart.js";
|
|
3
|
+
import { githubHandler } from "./platform/handlers/github.js";
|
|
4
|
+
import { githubGistHandler } from "./platform/handlers/githubGist.js";
|
|
5
|
+
import { lobstersHandler } from "./platform/handlers/lobsters.js";
|
|
6
|
+
import { redditHandler } from "./platform/handlers/reddit.js";
|
|
7
|
+
import { sourceforgeHandler } from "./platform/handlers/sourceforge.js";
|
|
8
|
+
import { tumblrHandler } from "./platform/handlers/tumblr.js";
|
|
1
9
|
import { behanceHandler } from "./platform/handlers/behance.js";
|
|
2
10
|
import { blogspotHandler } from "./platform/handlers/blogspot.js";
|
|
3
11
|
import { blueskyHandler } from "./platform/handlers/bluesky.js";
|
|
12
|
+
import { csdnHandler } from "./platform/handlers/csdn.js";
|
|
4
13
|
import { dailymotionHandler } from "./platform/handlers/dailymotion.js";
|
|
5
|
-
import { deviantartHandler } from "./platform/handlers/deviantart.js";
|
|
6
14
|
import { devtoHandler } from "./platform/handlers/devto.js";
|
|
7
|
-
import {
|
|
8
|
-
import { githubGistHandler } from "./platform/handlers/githubGist.js";
|
|
15
|
+
import { doubanHandler } from "./platform/handlers/douban.js";
|
|
9
16
|
import { gitlabHandler } from "./platform/handlers/gitlab.js";
|
|
17
|
+
import { goodreadsHandler } from "./platform/handlers/goodreads.js";
|
|
18
|
+
import { hashnodeHandler } from "./platform/handlers/hashnode.js";
|
|
19
|
+
import { hatenablogHandler } from "./platform/handlers/hatenablog.js";
|
|
20
|
+
import { itchioHandler } from "./platform/handlers/itchio.js";
|
|
10
21
|
import { kickstarterHandler } from "./platform/handlers/kickstarter.js";
|
|
11
|
-
import {
|
|
22
|
+
import { letterboxdHandler } from "./platform/handlers/letterboxd.js";
|
|
23
|
+
import { mastodonHandler } from "./platform/handlers/mastodon.js";
|
|
12
24
|
import { mediumHandler } from "./platform/handlers/medium.js";
|
|
25
|
+
import { paragraphHandler } from "./platform/handlers/paragraph.js";
|
|
13
26
|
import { pinterestHandler } from "./platform/handlers/pinterest.js";
|
|
14
27
|
import { producthuntHandler } from "./platform/handlers/producthunt.js";
|
|
15
|
-
import { redditHandler } from "./platform/handlers/reddit.js";
|
|
16
28
|
import { soundcloudHandler } from "./platform/handlers/soundcloud.js";
|
|
29
|
+
import { stackExchangeHandler } from "./platform/handlers/stackExchange.js";
|
|
30
|
+
import { steamHandler } from "./platform/handlers/steam.js";
|
|
17
31
|
import { substackHandler } from "./platform/handlers/substack.js";
|
|
18
|
-
import {
|
|
32
|
+
import { v2exHandler } from "./platform/handlers/v2ex.js";
|
|
33
|
+
import { vimeoHandler } from "./platform/handlers/vimeo.js";
|
|
19
34
|
import { wordpressHandler } from "./platform/handlers/wordpress.js";
|
|
35
|
+
import { wpengineHandler } from "./platform/handlers/wpengine.js";
|
|
36
|
+
import { ximalayaHandler } from "./platform/handlers/ximalaya.js";
|
|
20
37
|
import { youtubeHandler } from "./platform/handlers/youtube.js";
|
|
21
|
-
|
|
22
38
|
//#region src/feeds/defaults.ts
|
|
23
39
|
const mimeTypes = [
|
|
24
40
|
"application/rss+xml",
|
|
@@ -59,19 +75,13 @@ const urisComprehensive = [
|
|
|
59
75
|
"/feed.atom",
|
|
60
76
|
"/feed.rss.xml",
|
|
61
77
|
"/feed.atom.xml",
|
|
62
|
-
"/feed/atom/",
|
|
63
|
-
"/feed/rss/",
|
|
64
|
-
"/feed/rss2/",
|
|
65
|
-
"/feed/rdf",
|
|
66
|
-
"/feed/rdf/",
|
|
78
|
+
["/feed/atom/", "?feed=atom"],
|
|
79
|
+
["/feed/rss/", "?feed=rss"],
|
|
80
|
+
["/feed/rss2/", "?feed=rss2"],
|
|
81
|
+
["/feed/rdf", "?feed=rdf"],
|
|
82
|
+
["/feed/rdf/", "?feed=rdf"],
|
|
67
83
|
"/index.rss.xml",
|
|
68
84
|
"/index.atom.xml",
|
|
69
|
-
"?feed=rss",
|
|
70
|
-
"?feed=rss2",
|
|
71
|
-
"?feed=atom",
|
|
72
|
-
"?feed=rdf",
|
|
73
|
-
"?feed=comments-rss2",
|
|
74
|
-
"?feed=comments-atom",
|
|
75
85
|
"?format=rss",
|
|
76
86
|
"?format=atom",
|
|
77
87
|
"?rss=1",
|
|
@@ -81,7 +91,10 @@ const urisComprehensive = [
|
|
|
81
91
|
"/f.rss",
|
|
82
92
|
"/json",
|
|
83
93
|
"/.feed",
|
|
84
|
-
"/comments/feed",
|
|
94
|
+
["/comments/feed", "?feed=comments-rss2"],
|
|
95
|
+
["/comments/feed/rss2/", "?feed=comments-rss2"],
|
|
96
|
+
["/comments/feed/rdf/", "?feed=comments-rdf"],
|
|
97
|
+
["/comments/feed/atom/", "?feed=comments-atom"],
|
|
85
98
|
"/feeds/posts/default",
|
|
86
99
|
"/feeds/posts/default?alt=rss",
|
|
87
100
|
"/feeds/comments/default"
|
|
@@ -102,7 +115,7 @@ const linkSelectors = [{
|
|
|
102
115
|
}, { rel: "feed" }];
|
|
103
116
|
const defaultHtmlOptions = {
|
|
104
117
|
linkSelectors,
|
|
105
|
-
anchorUris: urisComprehensive,
|
|
118
|
+
anchorUris: urisComprehensive.flat(),
|
|
106
119
|
anchorIgnoredUris: ignoredUris,
|
|
107
120
|
anchorLabels
|
|
108
121
|
};
|
|
@@ -112,24 +125,40 @@ const defaultPlatformOptions = { handlers: [
|
|
|
112
125
|
behanceHandler,
|
|
113
126
|
blogspotHandler,
|
|
114
127
|
blueskyHandler,
|
|
128
|
+
csdnHandler,
|
|
129
|
+
codebergHandler,
|
|
130
|
+
doubanHandler,
|
|
115
131
|
deviantartHandler,
|
|
116
132
|
dailymotionHandler,
|
|
117
133
|
devtoHandler,
|
|
134
|
+
goodreadsHandler,
|
|
118
135
|
githubHandler,
|
|
136
|
+
hashnodeHandler,
|
|
137
|
+
hatenablogHandler,
|
|
119
138
|
githubGistHandler,
|
|
120
139
|
gitlabHandler,
|
|
140
|
+
itchioHandler,
|
|
121
141
|
kickstarterHandler,
|
|
142
|
+
letterboxdHandler,
|
|
143
|
+
lobstersHandler,
|
|
144
|
+
mastodonHandler,
|
|
122
145
|
mediumHandler,
|
|
146
|
+
paragraphHandler,
|
|
123
147
|
pinterestHandler,
|
|
124
148
|
producthuntHandler,
|
|
125
|
-
lobstersHandler,
|
|
126
149
|
redditHandler,
|
|
127
150
|
soundcloudHandler,
|
|
151
|
+
sourceforgeHandler,
|
|
152
|
+
stackExchangeHandler,
|
|
153
|
+
steamHandler,
|
|
128
154
|
substackHandler,
|
|
129
155
|
tumblrHandler,
|
|
156
|
+
v2exHandler,
|
|
157
|
+
vimeoHandler,
|
|
130
158
|
wordpressHandler,
|
|
159
|
+
wpengineHandler,
|
|
160
|
+
ximalayaHandler,
|
|
131
161
|
youtubeHandler
|
|
132
162
|
] };
|
|
133
|
-
|
|
134
163
|
//#endregion
|
|
135
|
-
export { anchorLabels, defaultGuessOptions, defaultHeadersOptions, defaultHtmlOptions, defaultPlatformOptions, ignoredUris, linkSelectors, mimeTypes, urisBalanced, urisComprehensive, urisMinimal };
|
|
164
|
+
export { anchorLabels, defaultGuessOptions, defaultHeadersOptions, defaultHtmlOptions, defaultPlatformOptions, ignoredUris, linkSelectors, mimeTypes, urisBalanced, urisComprehensive, urisMinimal };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
let feedsmith = require("feedsmith");
|
|
2
|
-
|
|
3
2
|
//#region src/feeds/extractors.ts
|
|
4
3
|
const getLinkOfType = (links, rel) => {
|
|
5
4
|
return links?.find((link) => link.rel === rel);
|
|
@@ -41,6 +40,5 @@ const defaultExtractor = async ({ content, url }) => {
|
|
|
41
40
|
isValid: false
|
|
42
41
|
};
|
|
43
42
|
};
|
|
44
|
-
|
|
45
43
|
//#endregion
|
|
46
|
-
exports.defaultExtractor = defaultExtractor;
|
|
44
|
+
exports.defaultExtractor = defaultExtractor;
|
package/dist/feeds/extractors.js
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { parseFeed } from "feedsmith";
|
|
2
|
-
|
|
3
2
|
//#region src/feeds/extractors.ts
|
|
4
3
|
const getLinkOfType = (links, rel) => {
|
|
5
4
|
return links?.find((link) => link.rel === rel);
|
|
@@ -41,6 +40,5 @@ const defaultExtractor = async ({ content, url }) => {
|
|
|
41
40
|
isValid: false
|
|
42
41
|
};
|
|
43
42
|
};
|
|
44
|
-
|
|
45
43
|
//#endregion
|
|
46
|
-
export { defaultExtractor };
|
|
44
|
+
export { defaultExtractor };
|
package/dist/feeds/index.cjs
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
const require_utils = require(
|
|
2
|
-
const require_utils$1 = require(
|
|
3
|
-
const require_index = require(
|
|
4
|
-
const require_defaults = require(
|
|
5
|
-
const require_extractors = require(
|
|
6
|
-
|
|
1
|
+
const require_utils = require("../common/utils.cjs");
|
|
2
|
+
const require_utils$1 = require("../common/discover/utils.cjs");
|
|
3
|
+
const require_index = require("../common/discover/index.cjs");
|
|
4
|
+
const require_defaults = require("./defaults.cjs");
|
|
5
|
+
const require_extractors = require("./extractors.cjs");
|
|
7
6
|
//#region src/feeds/index.ts
|
|
8
7
|
const discoverFeeds = async (input, options = {}) => {
|
|
9
8
|
return require_index.discover(input, {
|
|
@@ -24,6 +23,5 @@ const discoverFeeds = async (input, options = {}) => {
|
|
|
24
23
|
guess: require_defaults.defaultGuessOptions
|
|
25
24
|
});
|
|
26
25
|
};
|
|
27
|
-
|
|
28
26
|
//#endregion
|
|
29
|
-
exports.discoverFeeds = discoverFeeds;
|
|
27
|
+
exports.discoverFeeds = discoverFeeds;
|
package/dist/feeds/index.d.cts
CHANGED
|
@@ -2,6 +2,6 @@ import { DiscoverInput, DiscoverOptions, DiscoverResult } from "../common/types.
|
|
|
2
2
|
import { FeedResult } from "./types.cjs";
|
|
3
3
|
|
|
4
4
|
//#region src/feeds/index.d.ts
|
|
5
|
-
declare const discoverFeeds: <TValid extends FeedResult = FeedResult>(input: DiscoverInput, options?: DiscoverOptions<TValid>) => Promise<Array<DiscoverResult<TValid>>>;
|
|
5
|
+
declare const discoverFeeds: <TValid extends FeedResult = FeedResult>(input: DiscoverInput, options?: DiscoverOptions<TValid, "platform" | "html" | "headers" | "guess">) => Promise<Array<DiscoverResult<TValid>>>;
|
|
6
6
|
//#endregion
|
|
7
7
|
export { discoverFeeds };
|
package/dist/feeds/index.d.ts
CHANGED
|
@@ -2,6 +2,6 @@ import { DiscoverInput, DiscoverOptions, DiscoverResult } from "../common/types.
|
|
|
2
2
|
import { FeedResult } from "./types.js";
|
|
3
3
|
|
|
4
4
|
//#region src/feeds/index.d.ts
|
|
5
|
-
declare const discoverFeeds: <TValid extends FeedResult = FeedResult>(input: DiscoverInput, options?: DiscoverOptions<TValid>) => Promise<Array<DiscoverResult<TValid>>>;
|
|
5
|
+
declare const discoverFeeds: <TValid extends FeedResult = FeedResult>(input: DiscoverInput, options?: DiscoverOptions<TValid, "platform" | "html" | "headers" | "guess">) => Promise<Array<DiscoverResult<TValid>>>;
|
|
6
6
|
//#endregion
|
|
7
7
|
export { discoverFeeds };
|
package/dist/feeds/index.js
CHANGED
|
@@ -3,7 +3,6 @@ import { defaultFetchFn } from "../common/discover/utils.js";
|
|
|
3
3
|
import { discover } from "../common/discover/index.js";
|
|
4
4
|
import { defaultGuessOptions, defaultHeadersOptions, defaultHtmlOptions, defaultPlatformOptions } from "./defaults.js";
|
|
5
5
|
import { defaultExtractor } from "./extractors.js";
|
|
6
|
-
|
|
7
6
|
//#region src/feeds/index.ts
|
|
8
7
|
const discoverFeeds = async (input, options = {}) => {
|
|
9
8
|
return discover(input, {
|
|
@@ -24,6 +23,5 @@ const discoverFeeds = async (input, options = {}) => {
|
|
|
24
23
|
guess: defaultGuessOptions
|
|
25
24
|
});
|
|
26
25
|
};
|
|
27
|
-
|
|
28
26
|
//#endregion
|
|
29
|
-
export { discoverFeeds };
|
|
27
|
+
export { discoverFeeds };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
const require_utils = require(
|
|
2
|
-
|
|
1
|
+
const require_utils = require("../../../common/utils.cjs");
|
|
3
2
|
//#region src/feeds/platform/handlers/behance.ts
|
|
4
3
|
const hosts = ["behance.net", "www.behance.net"];
|
|
5
4
|
const userPathRegex = /^\/([a-zA-Z0-9_-]+)(?:\/(appreciated))?\/?$/;
|
|
@@ -33,13 +32,18 @@ const behanceHandler = {
|
|
|
33
32
|
const username = userMatch[1];
|
|
34
33
|
const subpage = userMatch[2];
|
|
35
34
|
if (!require_utils.isAnyOf(username, excludedPaths)) {
|
|
36
|
-
if (subpage === "appreciated") return [
|
|
37
|
-
|
|
35
|
+
if (subpage === "appreciated") return [{
|
|
36
|
+
uri: `https://www.behance.net/feeds/user?username=${username}&content=appreciated`,
|
|
37
|
+
hint: require_utils.composeHint("behance:appreciated")
|
|
38
|
+
}];
|
|
39
|
+
return [{
|
|
40
|
+
uri: `https://www.behance.net/feeds/user?username=${username}`,
|
|
41
|
+
hint: require_utils.composeHint("behance:portfolio")
|
|
42
|
+
}];
|
|
38
43
|
}
|
|
39
44
|
}
|
|
40
45
|
return [];
|
|
41
46
|
}
|
|
42
47
|
};
|
|
43
|
-
|
|
44
48
|
//#endregion
|
|
45
|
-
exports.behanceHandler = behanceHandler;
|
|
49
|
+
exports.behanceHandler = behanceHandler;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { isAnyOf, isHostOf } from "../../../common/utils.js";
|
|
2
|
-
|
|
1
|
+
import { composeHint, isAnyOf, isHostOf } from "../../../common/utils.js";
|
|
3
2
|
//#region src/feeds/platform/handlers/behance.ts
|
|
4
3
|
const hosts = ["behance.net", "www.behance.net"];
|
|
5
4
|
const userPathRegex = /^\/([a-zA-Z0-9_-]+)(?:\/(appreciated))?\/?$/;
|
|
@@ -33,13 +32,18 @@ const behanceHandler = {
|
|
|
33
32
|
const username = userMatch[1];
|
|
34
33
|
const subpage = userMatch[2];
|
|
35
34
|
if (!isAnyOf(username, excludedPaths)) {
|
|
36
|
-
if (subpage === "appreciated") return [
|
|
37
|
-
|
|
35
|
+
if (subpage === "appreciated") return [{
|
|
36
|
+
uri: `https://www.behance.net/feeds/user?username=${username}&content=appreciated`,
|
|
37
|
+
hint: composeHint("behance:appreciated")
|
|
38
|
+
}];
|
|
39
|
+
return [{
|
|
40
|
+
uri: `https://www.behance.net/feeds/user?username=${username}`,
|
|
41
|
+
hint: composeHint("behance:portfolio")
|
|
42
|
+
}];
|
|
38
43
|
}
|
|
39
44
|
}
|
|
40
45
|
return [];
|
|
41
46
|
}
|
|
42
47
|
};
|
|
43
|
-
|
|
44
48
|
//#endregion
|
|
45
|
-
export { behanceHandler };
|
|
49
|
+
export { behanceHandler };
|
|
@@ -1,10 +1,13 @@
|
|
|
1
|
-
|
|
1
|
+
const require_utils = require("../../../common/utils.cjs");
|
|
2
2
|
//#region src/feeds/platform/handlers/blogspot.ts
|
|
3
3
|
const blogspotDomainRegex = /^.+\.blogspot\.(?:com|co\.[a-z]{2}|com\.[a-z]{2}|[a-z]{2,3})$/;
|
|
4
4
|
const blogspotHandler = {
|
|
5
5
|
match: (url) => {
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
try {
|
|
7
|
+
const hostname = new URL(url).hostname.toLowerCase();
|
|
8
|
+
return blogspotDomainRegex.test(hostname);
|
|
9
|
+
} catch {}
|
|
10
|
+
return false;
|
|
8
11
|
},
|
|
9
12
|
resolve: (url) => {
|
|
10
13
|
const { origin, pathname } = new URL(url);
|
|
@@ -12,13 +15,21 @@ const blogspotHandler = {
|
|
|
12
15
|
const labelMatch = pathname.match(/^\/search\/label\/([^/]+)/);
|
|
13
16
|
if (labelMatch?.[1]) {
|
|
14
17
|
const label = labelMatch[1];
|
|
15
|
-
uris.push(
|
|
18
|
+
uris.push({
|
|
19
|
+
uri: `${origin}/feeds/posts/default/-/${label}`,
|
|
20
|
+
hint: require_utils.composeHint("blogspot:label")
|
|
21
|
+
});
|
|
16
22
|
}
|
|
17
|
-
uris.push(
|
|
18
|
-
|
|
23
|
+
uris.push({
|
|
24
|
+
uri: `${origin}/feeds/posts/default`,
|
|
25
|
+
hint: require_utils.composeHint("blogspot:posts-atom")
|
|
26
|
+
});
|
|
27
|
+
uris.push({
|
|
28
|
+
uri: `${origin}/feeds/posts/default?alt=rss`,
|
|
29
|
+
hint: require_utils.composeHint("blogspot:posts-rss")
|
|
30
|
+
});
|
|
19
31
|
return uris;
|
|
20
32
|
}
|
|
21
33
|
};
|
|
22
|
-
|
|
23
34
|
//#endregion
|
|
24
|
-
exports.blogspotHandler = blogspotHandler;
|
|
35
|
+
exports.blogspotHandler = blogspotHandler;
|
|
@@ -1,9 +1,13 @@
|
|
|
1
|
+
import { composeHint } from "../../../common/utils.js";
|
|
1
2
|
//#region src/feeds/platform/handlers/blogspot.ts
|
|
2
3
|
const blogspotDomainRegex = /^.+\.blogspot\.(?:com|co\.[a-z]{2}|com\.[a-z]{2}|[a-z]{2,3})$/;
|
|
3
4
|
const blogspotHandler = {
|
|
4
5
|
match: (url) => {
|
|
5
|
-
|
|
6
|
-
|
|
6
|
+
try {
|
|
7
|
+
const hostname = new URL(url).hostname.toLowerCase();
|
|
8
|
+
return blogspotDomainRegex.test(hostname);
|
|
9
|
+
} catch {}
|
|
10
|
+
return false;
|
|
7
11
|
},
|
|
8
12
|
resolve: (url) => {
|
|
9
13
|
const { origin, pathname } = new URL(url);
|
|
@@ -11,13 +15,21 @@ const blogspotHandler = {
|
|
|
11
15
|
const labelMatch = pathname.match(/^\/search\/label\/([^/]+)/);
|
|
12
16
|
if (labelMatch?.[1]) {
|
|
13
17
|
const label = labelMatch[1];
|
|
14
|
-
uris.push(
|
|
18
|
+
uris.push({
|
|
19
|
+
uri: `${origin}/feeds/posts/default/-/${label}`,
|
|
20
|
+
hint: composeHint("blogspot:label")
|
|
21
|
+
});
|
|
15
22
|
}
|
|
16
|
-
uris.push(
|
|
17
|
-
|
|
23
|
+
uris.push({
|
|
24
|
+
uri: `${origin}/feeds/posts/default`,
|
|
25
|
+
hint: composeHint("blogspot:posts-atom")
|
|
26
|
+
});
|
|
27
|
+
uris.push({
|
|
28
|
+
uri: `${origin}/feeds/posts/default?alt=rss`,
|
|
29
|
+
hint: composeHint("blogspot:posts-rss")
|
|
30
|
+
});
|
|
18
31
|
return uris;
|
|
19
32
|
}
|
|
20
33
|
};
|
|
21
|
-
|
|
22
34
|
//#endregion
|
|
23
|
-
export { blogspotHandler };
|
|
35
|
+
export { blogspotHandler };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
const require_utils = require(
|
|
2
|
-
|
|
1
|
+
const require_utils = require("../../../common/utils.cjs");
|
|
3
2
|
//#region src/feeds/platform/handlers/bluesky.ts
|
|
4
|
-
const hosts = ["bsky.app"];
|
|
3
|
+
const hosts = ["bsky.app", "www.bsky.app"];
|
|
5
4
|
const blueskyHandler = {
|
|
6
5
|
match: (url) => {
|
|
7
6
|
return require_utils.isHostOf(url, hosts);
|
|
@@ -10,9 +9,11 @@ const blueskyHandler = {
|
|
|
10
9
|
const { pathname } = new URL(url);
|
|
11
10
|
const handle = pathname.match(/^\/profile\/([^/]+)/)?.[1];
|
|
12
11
|
if (!handle) return [];
|
|
13
|
-
return [
|
|
12
|
+
return [{
|
|
13
|
+
uri: `https://bsky.app/profile/${handle}/rss`,
|
|
14
|
+
hint: require_utils.composeHint("bluesky:posts")
|
|
15
|
+
}];
|
|
14
16
|
}
|
|
15
17
|
};
|
|
16
|
-
|
|
17
18
|
//#endregion
|
|
18
|
-
exports.blueskyHandler = blueskyHandler;
|
|
19
|
+
exports.blueskyHandler = blueskyHandler;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import { isHostOf } from "../../../common/utils.js";
|
|
2
|
-
|
|
1
|
+
import { composeHint, isHostOf } from "../../../common/utils.js";
|
|
3
2
|
//#region src/feeds/platform/handlers/bluesky.ts
|
|
4
|
-
const hosts = ["bsky.app"];
|
|
3
|
+
const hosts = ["bsky.app", "www.bsky.app"];
|
|
5
4
|
const blueskyHandler = {
|
|
6
5
|
match: (url) => {
|
|
7
6
|
return isHostOf(url, hosts);
|
|
@@ -10,9 +9,11 @@ const blueskyHandler = {
|
|
|
10
9
|
const { pathname } = new URL(url);
|
|
11
10
|
const handle = pathname.match(/^\/profile\/([^/]+)/)?.[1];
|
|
12
11
|
if (!handle) return [];
|
|
13
|
-
return [
|
|
12
|
+
return [{
|
|
13
|
+
uri: `https://bsky.app/profile/${handle}/rss`,
|
|
14
|
+
hint: composeHint("bluesky:posts")
|
|
15
|
+
}];
|
|
14
16
|
}
|
|
15
17
|
};
|
|
16
|
-
|
|
17
18
|
//#endregion
|
|
18
|
-
export { blueskyHandler };
|
|
19
|
+
export { blueskyHandler };
|