No.3495
この機能では、投稿内にある1つ目の画像を問答無用で採用するので、1つ目の画像が「Twitter側がCardに求める様式」に該当していない場合は、Twitter Cardには画像が表示されないことになります。#🌱豆知識
一番よくありそうなケースは、SVGな気がします。Twitter CardはSVG形式の画像をサポートしていないので、SVG画像が1枚目にあるとTwitter Cardに画像は出ません。WebPは使えます。
JPG, PNG, WEBP and GIF formats are supported. Only the first frame of an animated GIF will be used. SVG is not supported.
https://developer.twitter.com/en/docs/twitter-for-webs...
あと、Twitter側が指定している条件は下記の通りです。
▼summary(小画像の場合):Twitterのドキュメント
Images for this Card support an aspect ratio of 1:1 with minimum dimensions of 144x144 or maximum of 4096x4096 pixels. Images must be less than 5MB in size. The image will be cropped to a square on all platforms.
➡ 縦横比 1:1、最小サイズ 144x144、最大サイズ 4096x4096 ピクセル。画像サイズは 5MB まで。画像は正方形にトリミングされる。
▼summary_large_image(大画像の場合):Twitterのドキュメント
Images for this Card support an aspect ratio of 2:1 with minimum dimensions of 300x157 or maximum of 4096x4096 pixels. Images must be less than 5MB in size.
➡ 縦横比 2:1、最小サイズ 300x157、最大サイズ 4096x4096 ピクセル。画像サイズは 5MB まで。
- ユーザ「にしし」の投稿だけを見る (※時系列順で見る)
- この投稿と同じカテゴリに属する投稿:
- この投稿日時に関連する投稿:
- この投稿に隣接する前後3件ずつをまとめて見る
- この投稿を再編集または削除する