Blog Feature Showcase
Blog Feature Showcase
This blog post demonstrates all the features supported in this portfolio blog system. From basic formatting to advanced features like syntax-highlighted code, mermaid diagrams, tables, and embedded media.
๐จ Text Formatting
Basic Formatting
Bold text using double asterisks or double underscores
Italic text using single asterisks or single underscores
Bold and italic using triple asterisks
Strikethrough text using double tildes
Inline Elements
Use inline code for technical terms or commands like npm install
Hereโs a link to GitHub and hereโs an internal link
Paragraphs and Line Breaks
This is a paragraph with some text. It continues on the same line until you add a blank line.
This is a new paragraph. Notice the spacing between paragraphs creates nice visual separation for better readability.
๐ Headings Hierarchy
Heading 1
Heading 2
Heading 3
Heading 4
Heading 5
Heading 6
๐ฌ Blockquotes
โThe best way to predict the future is to invent it.โ โ Alan Kay
Blockquotes can contain other markdown elements
- Including lists
- And
code- Even italic text
const wisdom = "Code is poetry";const wisdom = "Code is poetry";
Nested Blockquotes
This is the first level of quoting.
This is nested blockquote.
You can nest them even deeper!
๐ Lists
Unordered Lists
- First item
- Second item
- Third item
- Nested item 1
- Nested item 2
- Deeply nested item
- Another deeply nested item
- Fourth item
Ordered Lists
- First step
- Second step
- Third step
- Substep A
- Substep B
- Substep C
- Fourth step
Mixed Lists
- Start with a numbered item
- Add a bulleted sub-item
- And another
- Continue with numbers
- More bullets
- Even deeper bullets
- Going deeper
- Even deeper bullets
- More bullets
- Final numbered item
Task Lists
- [x] Completed task
- [x] Another completed task
- [ ] Pending task
- [ ] Another pending task
- [x] Subtask completed
- [ ] Subtask pending
๐ป Code Blocks
Inline Code
Use backticks for inline code: const variable = "value"
Install packages with: npm install package-name
JavaScript Code Block
// Function to calculate fibonacci numbers
function fibonacci(n) {
if (n <= 1) return n;
return fibonacci(n - 1) + fibonacci(n - 2);
}
// Using modern JavaScript features
const numbers = [1, 2, 3, 4, 5];
const doubled = numbers.map(n => n * 2);
console.log(doubled); // [2, 4, 6, 8, 10]
// Function to calculate fibonacci numbers
function fibonacci(n) {
if (n <= 1) return n;
return fibonacci(n - 1) + fibonacci(n - 2);
}
// Using modern JavaScript features
const numbers = [1, 2, 3, 4, 5];
const doubled = numbers.map(n => n * 2);
console.log(doubled); // [2, 4, 6, 8, 10]
TypeScript Code Block
interface User {
id: number;
name: string;
email: string;
isActive: boolean;
}
class UserManager {
private users: User[] = [];
addUser(user: User): void {
this.users.push(user);
}
getActiveUsers(): User[] {
return this.users.filter(user => user.isActive);
}
}
const manager = new UserManager();
interface User {
id: number;
name: string;
email: string;
isActive: boolean;
}
class UserManager {
private users: User[] = [];
addUser(user: User): void {
this.users.push(user);
}
getActiveUsers(): User[] {
return this.users.filter(user => user.isActive);
}
}
const manager = new UserManager();
Python Code Block
# Python example with syntax highlighting
def quicksort(arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)
# Using list comprehensions
numbers = [3, 6, 8, 10, 1, 2, 1]
sorted_numbers = quicksort(numbers)
print(sorted_numbers)
# Python example with syntax highlighting
def quicksort(arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)
# Using list comprehensions
numbers = [3, 6, 8, 10, 1, 2, 1]
sorted_numbers = quicksort(numbers)
print(sorted_numbers)
CSS Code Block
/* Modern CSS with custom properties */
:root {
--primary-color: #019b59;
--secondary-color: #0f172a;
--accent-gradient: linear-gradient(135deg, #019b59, #00d97e);
}
.card {
background: var(--secondary-color);
border-radius: 12px;
padding: 2rem;
backdrop-filter: blur(10px);
box-shadow: 0 8px 32px rgba(1, 155, 89, 0.15);
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.card:hover {
transform: translateY(-4px);
box-shadow: 0 12px 48px rgba(1, 155, 89, 0.25);
}
/* Modern CSS with custom properties */
:root {
--primary-color: #019b59;
--secondary-color: #0f172a;
--accent-gradient: linear-gradient(135deg, #019b59, #00d97e);
}
.card {
background: var(--secondary-color);
border-radius: 12px;
padding: 2rem;
backdrop-filter: blur(10px);
box-shadow: 0 8px 32px rgba(1, 155, 89, 0.15);
transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.card:hover {
transform: translateY(-4px);
box-shadow: 0 12px 48px rgba(1, 155, 89, 0.25);
}
HTML Code Block
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sample Page</title>
</head>
<body>
<header>
<nav>
<ul>
<li><a href="#home">Home</a></li>
<li><a href="#about">About</a></li>
<li><a href="#contact">Contact</a></li>
</ul>
</nav>
</header>
<main>
<h1>Welcome to my site!</h1>
<p>This is a sample HTML document.</p>
</main>
</body>
</html>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Sample Page</title>
</head>
<body>
<header>
<nav>
<ul>
<li><a href="#home">Home</a></li>
<li><a href="#about">About</a></li>
<li><a href="#contact">Contact</a></li>
</ul>
</nav>
</header>
<main>
<h1>Welcome to my site!</h1>
<p>This is a sample HTML document.</p>
</main>
</body>
</html>
Bash/Shell Commands
# Navigate to project directory
cd /path/to/project
# Install dependencies
npm install
# Start development server
npm run dev
# Build for production
npm run build
# Deploy to production
npm run deploy
# Navigate to project directory
cd /path/to/project
# Install dependencies
npm install
# Start development server
npm run dev
# Build for production
npm run build
# Deploy to production
npm run deploy
JSON Example
{
"name": "my-portfolio",
"version": "1.0.0",
"description": "Modern portfolio with blog",
"scripts": {
"dev": "astro dev",
"build": "astro build",
"preview": "astro preview"
},
"dependencies": {
"astro": "^4.3.2",
"markdown-it": "^14.1.0"
}
}
{
"name": "my-portfolio",
"version": "1.0.0",
"description": "Modern portfolio with blog",
"scripts": {
"dev": "astro dev",
"build": "astro build",
"preview": "astro preview"
},
"dependencies": {
"astro": "^4.3.2",
"markdown-it": "^14.1.0"
}
}
๐ Mermaid Diagrams
This blog supports Mermaid diagrams for creating beautiful flowcharts, sequence diagrams, and more!
Flowchart
graph TD
A[Start] --> B{Is it working?}
B -->|Yes| C[Great!]
B -->|No| D[Debug]
D --> E[Fix the bug]
E --> B
C --> F[Deploy]
F --> G[End]
Sequence Diagram
sequenceDiagram
participant User
participant Browser
participant Server
participant Database
User->>Browser: Enter URL
Browser->>Server: HTTP Request
Server->>Database: Query Data
Database-->>Server: Return Data
Server-->>Browser: HTTP Response
Browser-->>User: Display Page
Git Graph
gitGraph
commit id: "Initial commit"
commit id: "Add homepage"
branch develop
checkout develop
commit id: "Add blog feature"
commit id: "Fix styling"
checkout main
merge develop
commit id: "Release v1.0"
Class Diagram
classDiagram
class User {
+String name
+String email
+login()
+logout()
}
class BlogPost {
+String title
+String content
+Date publishDate
+publish()
+delete()
}
class Comment {
+String text
+Date createdAt
+approve()
}
User "1" --> "*" BlogPost : writes
BlogPost "1" --> "*" Comment : has
State Diagram
stateDiagram-v2
[*] --> Draft
Draft --> Review : Submit
Review --> Published : Approve
Review --> Draft : Request Changes
Published --> Archived : Archive
Archived --> [*]
Pie Chart
pie title Programming Languages Usage
"JavaScript" : 45
"TypeScript" : 30
"Python" : 15
"CSS" : 10
๐ Tables
Simple Table
| Feature | Status | Priority |
|---|---|---|
| Dark Mode | โ Completed | High |
| Blog System | โ Completed | High |
| Comments | โ Completed | Medium |
| Analytics | ๐ง In Progress | Low |
Aligned Columns
| Left Aligned | Center Aligned | Right Aligned |
|---|---|---|
| Text | Text | Text |
| More text | More text | More text |
| Even more | Even more | Even more |
Complex Table with Formatting
| Language | Use Case | Difficulty | Popularity |
|---|---|---|---|
| JavaScript | Web Development | โญโญ | ๐ฅ๐ฅ๐ฅ |
| Python | Data Science | โญ | ๐ฅ๐ฅ๐ฅ |
| Rust | Systems Programming | โญโญโญโญ | ๐ฅ๐ฅ |
| TypeScript | Type-safe JS | โญโญ | ๐ฅ๐ฅ๐ฅ |
๐ Links and References
External Links
Visit my GitHub to see my projects.
Check out Astro documentation for more info.
Reference-style Links
Anchor Links (Internal)
Jump to Tables section or Code Blocks
๐ผ๏ธ Images
Standard Image
๐ฅ Embedded Media
YouTube Video Embed
You can embed YouTube videos using HTML:
GIF Images

Video Element (MP4)
๐ฏ HTML Elements
Custom Styled Div
Custom Styled Section
You can use HTML directly in markdown for custom styling and layouts!
Colored Text
This text is colored with the accent color!
And this text is red and italic!
Highlight Box
โ ๏ธ Special Sections
Warning Box
Error Box
Success Box
๐ Mathematical Expressions
While native LaTeX isnโt supported, you can use Unicode symbols:
- Area of circle: A = ฯrยฒ
- Pythagorean theorem: aยฒ + bยฒ = cยฒ
- Summation: ฮฃ(n) from i=1 to n
- Infinity: โ
- Delta: ฮx
- Integral: โซf(x)dx
๐จ Horizontal Rules
You can create horizontal rules using three or more hyphens, asterisks, or underscores:
๐ค Special Characters & Emojis
Emojis Work Great! ๐
โจ Sparkles โญ Star ๐ Rocket ๐ก Idea ๐ฏ Target ๐ฅ Fire
โค๏ธ Heart ๐ Thumbs Up ๐จ Art ๐ฑ Mobile ๐ป Laptop ๐ Glowing Star
Special Characters
Copyright ยฉ | Registered ยฎ | Trademark โข | En Dash โ | Em Dash โ
Arrows: โ โ โ โ | Quotes: " " โ โ | Ellipsis: โฆ
๐ฆ Code with Line Numbers (Simulated)
1 | // Binary search implementation
2 | function binarySearch(arr, target) {
3 | let left = 0;
4 | let right = arr.length - 1;
5 |
6 | while (left <= right) {
7 | const mid = Math.floor((left + right) / 2);
8 |
9 | if (arr[mid] === target) {
10 | return mid;
11 | } else if (arr[mid] < target) {
12 | left = mid + 1;
13 | } else {
14 | right = mid - 1;
15 | }
16 | }
17 |
18 | return -1;
19 | }
1 | // Binary search implementation
2 | function binarySearch(arr, target) {
3 | let left = 0;
4 | let right = arr.length - 1;
5 |
6 | while (left <= right) {
7 | const mid = Math.floor((left + right) / 2);
8 |
9 | if (arr[mid] === target) {
10 | return mid;
11 | } else if (arr[mid] < target) {
12 | left = mid + 1;
13 | } else {
14 | right = mid - 1;
15 | }
16 | }
17 |
18 | return -1;
19 | }
๐ญ Definition Lists (Using HTML)
- HTML
- HyperText Markup Language - The standard markup language for web pages.
- CSS
- Cascading Style Sheets - Used for styling HTML elements.
- JavaScript
- A programming language that enables interactive web pages.
๐ช Keyboard Shortcuts
Press Ctrl + C to copy
Press Cmd + V to paste
Press Ctrl + Alt + Delete for task manager
๐ Conclusion
This blog post demonstrates all the rich features available in this portfolio blog system, including:
โ Text Formatting - Bold, italic, strikethrough, inline code โ Headings - All 6 levels with proper hierarchy โ Blockquotes - Including nested and styled quotes โ Lists - Ordered, unordered, nested, and task lists โ Code Blocks - Syntax highlighted in multiple languages โ Mermaid Diagrams - Flowcharts, sequence diagrams, git graphs, and more โ Tables - With alignment and formatting โ Links - External, internal, and reference-style โ Images - With captions and titles โ Videos & GIFs - Embedded media support โ HTML - Custom styling and layouts โ Special Characters - Emojis and symbols โ Horizontal Rules - Section separators
Happy blogging! ๐
Comments