On Tags (including Hash-Tags) in ActivityPub.
-
On Tags (including Hash-Tags) in ActivityPub.
1/
I think new developers coming to ActivityPub want to write something like:
"tag": ["apple", "banana", "cherry"]
It is unfortunate that that isn't valid ActivityPub. But, that it must instead be:
"tag": [
{
"type": "Hashtag",
"name": "#apple"
},
{
"type": "Hashtag",
"name": "#banana"
},
{
"type": "Hashtag",
"name": "#cherry"
}
]...
#ActivityPub #ActivityStreams #FediDev #HashTag #HashTags #Tag #Tags
-
On Tags (including Hash-Tags) in ActivityPub.
1/
I think new developers coming to ActivityPub want to write something like:
"tag": ["apple", "banana", "cherry"]
It is unfortunate that that isn't valid ActivityPub. But, that it must instead be:
"tag": [
{
"type": "Hashtag",
"name": "#apple"
},
{
"type": "Hashtag",
"name": "#banana"
},
{
"type": "Hashtag",
"name": "#cherry"
}
]...
#ActivityPub #ActivityStreams #FediDev #HashTag #HashTags #Tag #Tags
On Tags (including Hash-Tags) in ActivityPub.
2/
A new version of ActivityPub could extend the type of "tag" from:
Object | Link
to:
Object | Link | xsd:string
And that would make the following valid ActivityPub:
"tag": ["apple", "banana", "cherry"]
Of course, it would have to be specified how to interpret this. (Ex: as "type":"Hashtag", or whatever.)
#ActivityPub #ActivityStreams #FediDev #HashTag #HashTags #Tag #Tags
-
On Tags (including Hash-Tags) in ActivityPub.
1/
I think new developers coming to ActivityPub want to write something like:
"tag": ["apple", "banana", "cherry"]
It is unfortunate that that isn't valid ActivityPub. But, that it must instead be:
"tag": [
{
"type": "Hashtag",
"name": "#apple"
},
{
"type": "Hashtag",
"name": "#banana"
},
{
"type": "Hashtag",
"name": "#cherry"
}
]...
#ActivityPub #ActivityStreams #FediDev #HashTag #HashTags #Tag #Tags
@reiver i don't mind
typebut the leading hash always feels redundant -
On Tags (including Hash-Tags) in ActivityPub.
1/
I think new developers coming to ActivityPub want to write something like:
"tag": ["apple", "banana", "cherry"]
It is unfortunate that that isn't valid ActivityPub. But, that it must instead be:
"tag": [
{
"type": "Hashtag",
"name": "#apple"
},
{
"type": "Hashtag",
"name": "#banana"
},
{
"type": "Hashtag",
"name": "#cherry"
}
]...
#ActivityPub #ActivityStreams #FediDev #HashTag #HashTags #Tag #Tags
There's a definition for
Hashtaghere: -
On Tags (including Hash-Tags) in ActivityPub.
1/
I think new developers coming to ActivityPub want to write something like:
"tag": ["apple", "banana", "cherry"]
It is unfortunate that that isn't valid ActivityPub. But, that it must instead be:
"tag": [
{
"type": "Hashtag",
"name": "#apple"
},
{
"type": "Hashtag",
"name": "#banana"
},
{
"type": "Hashtag",
"name": "#cherry"
}
]...
#ActivityPub #ActivityStreams #FediDev #HashTag #HashTags #Tag #Tags
@reiver@mastodon.social hmm, I don't much mind the
"type": "Hashtag"bit. Additional specificity is helpful in the long-run I think.For example,
tagcontains hashtags, but it also contains mentions,"type": "Mention", so that actually makes sense.Additional stuff that falls under the rather general name "tag" could also fit. Tagging a location, tagging an Event, etc.
This might also be what @evan was talking about, I didn't click through his link yet <img class="not-responsive emoji" src="https://activitypub.space/assets/plugins/nodebb-plugin-emoji/emoji/android/1f61c.png?v=f187f9278b7" title=":stuck_out_tongue_winking_eye:" />
-
@reiver i don't mind
typebut the leading hash always feels redundant> @toddsundsted@epiktistes.com said:
>
> <p><a href="/user/reiver%40mastodon.social" rel="tag">@reiver</a> i don't mind <code>type</code> but the leading hash always feels redundant</p>haha don't worry, it's optional.
And by optional, I mean there's no specification about it, and so it's de facto part of it because Mastodon does it, but importantly, Peertube doesn't!
So you can really just do whatever you want. Omit the #, I think Mastodon and most other software handles it fine.
-
Ciao! Sembra che tu sia interessato a questa conversazione, ma non hai ancora un account.
Stanco di dover scorrere gli stessi post a ogni visita? Quando registri un account, tornerai sempre esattamente dove eri rimasto e potrai scegliere di essere avvisato delle nuove risposte (tramite email o notifica push). Potrai anche salvare segnalibri e votare i post per mostrare il tuo apprezzamento agli altri membri della comunità.
Con il tuo contributo, questo post potrebbe essere ancora migliore 💗
Registrati Accedi