You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docsify-xpost is a Docsify plugin that allows you to easily embed stylized content blocks resembling X (formerly Twitter) posts directly within your Markdown files. Enhance your documentation by showcasing examples, quotes, or announcements in a familiar and visually appealing format.
Features
Simple Integration: Embed posts using intuitive Markdown comments.
<head><!-- ... other head elements ... --><linkrel="stylesheet"
href="https://cdn.jsdelivr.net/npm/docsify-xpost/docsify-xpost.css"
/></head>
Usage
To embed an X-like post in your Markdown content, wrap your content and metadata within <!-- x:start --> and <!-- x:end --> comments. Use specific comment formats <!-- key:value --> to define the post's metadata.
Available Metadata Keys:
avatarUrl: URL of the user's profile picture.
imageUrl: (Optional) URL of an image attached to the post.
username: Display name of the user.
userId: The user's handle (e.g., @handle).
timestamp: The post's date or time string.
likes: Number of likes.
retweets: Number of retweets.
comments: Number of comments.
views: Number of views.
Example:
<!-- x:start --><!-- avatarUrl:'https://pbs.twimg.com/profile_images/1893803697185910784/Na5lOWi5_400x400.jpg' --><!-- imageUrl:'https://pbs.twimg.com/media/GobIp2wX0AE9zOp?format=jpg&name=small' --><!-- username:kevin --><!-- userId:kevin12134 --><!-- timestamp:Apr 13 --><!-- likes:13423 --><!-- retweets:13423 --><!-- comments:123 --><!-- views:321 -->
This is the main content of your x post.
It can span multiple lines.
Nice to meet you! Hello, docsify-xpost!
<!-- x:end -->
About
A Docsify plugin for rendering content blocks that resemble X posts.