-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: warn when using .svg
in meta.image
#377
Conversation
Run & review this pull request in StackBlitz Codeflow. |
docs/tutorialkit.dev/src/content/docs/reference/configuration.mdx
Outdated
Show resolved
Hide resolved
docs/tutorialkit.dev/src/content/docs/reference/configuration.mdx
Outdated
Show resolved
Hide resolved
Let's host a static png/jpg on |
.svg
in meta.image
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks @eric-burel!
I'll do a follow-up PR that changes the default og-image to 'https://tutorialkit.dev/tutorialkit-opengraph.png'
instead of logo.svg
.
I figured the hard way that most social platforms won't actually support SVG open graph cover images, which might be confusing since we use the logo as the default cover image, and the default logo is SVG.
I've added a warning to detect this scenario, and added some documentation.
Maybe we could later improve the default setup to provide a default .png cover image directly? I've tested setting "meta.image" at tutorial level for all lessons and it works perfect, so maybe we could include a TutorialKit cover as "cover.png" and configure it directly there, rather than falling back on the logo.