Commit Graph

7 Commits

Author SHA1 Message Date
Bin Wang 6b7381e1e3
feat(core): add custom fields to atom feed (#9355)
* Add custom fields to atom feed

Atom allows to extend the xml with custom namespaces. This commit is
a first commit that tries to add some custom RSSHub fields to atom feed.

In this commit, I added three very common fields: upvotes, downvotes
and comments. Lots of websites has these common fields, like Youtube,
Twitter, Reddit, HackerNews and so on. Within these fields, RSS readers
can have more information to sort the contents, and can display these
information to user in a better format.

The document has been updated to reflect these new fields. I also changed
Bilibili video route as an example to show how to add number of comments
to the generated feed.

* docs: interactions
2022-04-18 02:54:32 +08:00
Rongrong 5b35471e39
fix(core): offending RFC4287 (#9441)
* fix(core): offending RFC4287

should not leave `<updated>` blank when `<published>` is not blank
these two fields MUST conform to the "date-time" production in RFC3339

Signed-off-by: Rongrong <15956627+Rongronggg9@users.noreply.github.com>

* test(common-utils): complete tests

Signed-off-by: Rongrong <15956627+Rongronggg9@users.noreply.github.com>

* test(template): restrict expected value of `pubDate`

Signed-off-by: Rongrong <15956627+Rongronggg9@users.noreply.github.com>
2022-04-02 17:44:45 +08:00
Queensferry 8ebbd0d708
fix: [core] atom feed template (#6628) (#6726)
conforming to RFC 4278 4.1.3.3. Processing Model
2021-01-25 20:21:32 -05:00
tuzi3040 52cf1cab71
fix: atom.art id (#5401) 2020-08-18 21:13:29 +01:00
Cloud 4d9c9c08e7 feat: 2 rules for feed validation (#2825) 2019-08-11 01:30:59 +08:00
DIYgod 0a62389eaa
test: middleware/template 2019-01-31 11:45:00 +08:00
DIYgod 38a90e29b0
optimize directory structure 2018-12-26 18:35:10 +08:00