ikiwiki/doc/todo/support_Twitter_cards.mdwn

21 lines
1.4 KiB
Plaintext
Raw Normal View History

2020-09-11 19:50:24 +02:00
[Twitter cards](https://developer.twitter.com/en/docs/twitter-for-websites/cards/overview/summary-card-with-large-image) work by using `<meta>` tags with names that include a colon: `twitter:card`, `twitter:site`, `twitter:creator`, etc.
The current parsing of ikiwiki's directive doesn't support using colons in names.
This patch fixes it.
Disclaimer: I don't know anything about Perl or the internals of ikiwiki but I managed to "make it work". It might still be flawed in many ways.
Twitter is not really picky about HTML and actually parses `<meta>` tags outside of the `<head>` section, so there's currently a workaround.
That's what I did on the [donation page of Tails](https://gitlab.tails.boum.org/tails/tails/-/commit/6dbde9fa926e574b3bab4170caf65fe3c394fe48) for now.
2020-09-11 19:54:24 +02:00
2020-10-13 12:16:34 +02:00
> Hi! Thanks for looking at this. Correct me if I misunderstand your message. I think you are saying
> that this bug with colons remains in IkiWiki's parser, and you have not fixed that, but you have a
> a workaround, namely putting the meta tags as HTML into the body of the page? That's a useful
> workaround and worthy of documenting, but it's not a "patch" so I have removed the patch tag.
>
> If, instead, you have actually got a patch for the IkiWiki parser, please post it and I can take a
> look: I'm not an IkiWiki maintainer but I can review it and give my opinion at least. If that's the
> case, please share it, and re-add `\[[!tag patch]]`. Thanks! *—[[Jon]], 2020-10-13*