LogoMkSaaS Docs
LogoMkSaaS Docs
HomepageIntroductionCodebaseVideo TutorialsGetting StartedEnvironment Setup
Configuration

Integrations

DatabaseAuthenticationEmailNewsletterStoragePaymentCreditsCron JobsAIAnalyticsNotificationCaptchaChatboxAffiliates

Customization

MetadataFontsThemesImagesi18nBlogDocsComponentsCustom PagesLanding PageUser ManagementAPI Key Management

Codebase

IDE SetupProject StructureFormatting & LintingUpdating the Codebase
X (Twitter)

Blog

Learn how to create, manage, and customize blog posts with multi-language support

MkSaaS includes a blog system built with Fumadocs MDX, supporting multi-language content, categories, authors, and rich content formatting.

Blog

Creating Blog Content

Adding a New Author

Create a new MDX file in the content/author directory:

content/author/john-doe.mdx
---
name: John Doe
avatar: /images/authors/john-doe.jpg
---

Adding a New Category

Create a new MDX file in the content/category directory:

content/category/tutorial.mdx
---
name: Tutorial
description: Step-by-step guides to learn new features
---

Adding a New Blog Post

Create a new MDX file in the content/blog directory:

content/blog/my-first-post.mdx
---
title: My First Blog Post
description: This is a brief description of my first blog post.
image: https://cdn.mksaas.com/mksaas/images/blog/my-first-post.jpg
date: "2023-12-01"
published: true
categories: ["tutorial", "announcement"]
author: "mksaas"
---

# Introduction

This is my first blog post. Here I'll talk about something interesting.

## Section 1

Some content here...

## Section 2

More content here...

Multi-language Support

MkSaaS blog system fully supports internationalization. You can create content in multiple languages using the following file naming convention:

  1. Default locale (e.g., English): filename.mdx
  2. Other locales (e.g., Chinese): filename.zh.mdx

Multi-language Authors and Categories

Follow the same pattern for authors and categories:

content/author/mksaas.zh.mdx
---
name: MkSaaS å›ĸ队
avatar: /images/authors/mksaas.jpg
---
content/category/announcement.zh.mdx
---
name: å…Ŧ告
description: åŽ˜æ–šåšŗå°å…Ŧ告和更新
---

Multi-language Blog Post Example

For an English blog post:

content/blog/welcome-post.mdx
---
title: Welcome to our Blog
description: Our first official blog post
image: https://cdn.mksaas.com/mksaas/images/blog/welcome.jpg
date: "2023-12-01"
published: true
categories: ["announcement"]
author: "mksaas"
---

Content in English...

For the same post in Chinese:

content/blog/welcome-post.zh.mdx
---
title: æŦĸčŋŽæĨ到我äģŦįš„åšåŽĸ
description: 我äģŦįš„įŦŦä¸€į¯‡åŽ˜æ–šåšåŽĸ文įĢ 
image: https://cdn.mksaas.com/mksaas/images/blog/welcome.jpg
date: "2023-12-01"
published: true
categories: ["announcement"]
author: "mksaas"
---

Content in Chinese...

Premium Content

You can create premium content by adding the premium field set to true to the blog post:

content/blog/premium.mdx
---
title: Premium Post
...
premium: true
---

This is the free content part.

...

<PremiumContent>

This is the paid content part.

...

</PremiumContent>

If the blog post is premium, there will be a premium badge in the blog card.

Blog Premium Badge

If user is not logged in, they can only see the free content part.

Blog Login Required

If user is logged in, but they are not a premium user, they can see the free content part.

Blog Upgrade Required

If user is logged in, and they are a premium user, they can see the paid content part.

Blog Premium Content

Customization

Customizing the Blog Schema

To add new fields to blog posts, authors, or categories:

  1. Modify the schema in source.config.ts
  2. Run pnpm run content to regenerate the .source folder
  3. Update components to display the new fields

Changing Blog Post Card Layout

Customize the blog card component in src/components/blog/blog-card.tsx.

Video Tutorial

Next Steps

Documentation

Learn how to create the documentation

i18n

Configure multi-language support

Newsletter

Configure newsletter

Website Configuration

Configure website settings

Table of Contents

Creating Blog Content
Adding a New Author
Adding a New Category
Adding a New Blog Post
Multi-language Support
Multi-language Authors and Categories
Multi-language Blog Post Example
Premium Content
Customization
Customizing the Blog Schema
Changing Blog Post Card Layout
Video Tutorial
Next Steps