Feature Request: `<link rel="alternate" type="application/activity+json">`
What
Consider adding the link rel=alternate element as you can see in Mastodon/Misskey, e.g. in https://fosstodon.org/@krosylight:
<link href='https://fosstodon.org/@krosylight.rss' rel='alternate' type='application/rss+xml'>
<link href='https://fosstodon.org/users/krosylight' rel='alternate' type='application/activity+json'>
Why
This element advertises that the page can be read in ActivityPub form too. Browser extensions can detect it and reopen it on Mastodon for example.
How
No response
I thought about that a lot and wanted to write a FEP to use rel-alternate as alternative to content negotiation!
My issue with the current implementations is that it still needs conneg, but I would expect that it should work similar to the RSS link header (you referenced) instead. That means that it should return Activity-JSON by default, regardless of the Accept header.
From the HTML spec:
If the alternate keyword is used with the type attribute, it indicates that the referenced document is a reformulation of the current document in the specified format.
So it should be more like
<link href='https://fosstodon.org/@krosylight.json' rel='alternate' type='application/activity+json'>
instead!
See https://github.com/mastodon/mastodon/issues/22306
This issue is stale because it has been open 120 days with no activity. Remove stale label or comment or this will be closed in 5 days.
Have you written an RFP? 👀