Skip to content

Commit 53e1fca

Browse files
authored
Merge pull request #3 from dhub-dev/update-blog-and-docs-content
Update Blog and Docs Content
2 parents ad92328 + cd9a95f commit 53e1fca

File tree

9 files changed

+124
-122
lines changed

9 files changed

+124
-122
lines changed
Lines changed: 38 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,44 @@
11
---
22
slug: how-it-works
33
title: Learn How Docusaurus Works
4-
authors: [personX]
4+
authors: [wonderful-person]
55
tags: [dhub, docusaurus, features]
66
---
77

88
# Learn How Docusaurus Works
99

10-
This page is your gateway to understanding the essential features that make your blog tick. Get ready to explore the key elements that make Docusaurus a powerful tool for bloggers.
10+
This page is your gateway to understanding the essential features of
11+
Dhub and Docusaurus.
1112

1213
### Framework
1314

14-
[Docusaurus blogging features](https://docusaurus.io/docs/blog) are powered by the [blog plugin](https://docusaurus.io/docs/api/plugins/@docusaurus/plugin-content-blog). Simply add Markdown files (or folders) to the `blog` directory. The blog post date can be extracted from filenames, such as:
15+
Blog is powered by the [blog plugin](https://docusaurus.io/docs/api/plugins/@docusaurus/plugin-content-blog). Simply add Markdown files (or folders) to the `blog` directory. The blog post date can be extracted from filenames, such as:
1516

1617
- `2024-01-21.md`
17-
- `2024-01-21-how-it-works/index.md`
18+
- `2024-01-21-how-it-works/index.mdx`
1819

1920
### Page structure
2021

21-
Docusaurus relies on _frontmatter variables_ to generate the blog post page. Instead of using the Heading-1 level title from the content, it extracts information from these variables:
22+
Docusaurus relies on _frontmatter variables_ to generate the blog post page.
23+
24+
Some information is used from variables at the start of the file, here's an example of the frontmatter structure:
2225

2326
```
27+
---
2428
slug: page-url-slug
25-
title: The title Docusaurus uses to show in a page
26-
authors: [ceo, arijus]
29+
title: The title to show in a page
30+
authors: [wonderful-person]
2731
tags: [any, words, here, become, tags]
32+
---
33+
34+
## The content of the page starts here
2835
```
2936

30-
Understanding this structure ensures a cohesive layout for your blog pages, allowing for a personalized and organized reader experience.
37+
:::tip
38+
39+
Dhub supports the frontmatter structure and provides a user-friendly interface to manage it.
40+
41+
:::
3142

3243
### Images
3344

@@ -37,11 +48,11 @@ Explore two ways to add visuals to your blog:
3748

3849
Keep your images in a centralized folder. Upload them to `/static/img/`:
3950

40-
[![A closeup shot of rocks](/img/rocks.jpg 'A photo by Nick Nice')](https://unsplash.com/photos/shallow-focus-photography-of-gravels-zwjSCTItiZU)
51+
[![A closeup shot of rocks](/img/rocks.jpg "A photo by Nick Nice")](https://unsplash.com/photos/shallow-focus-photography-of-gravels-zwjSCTItiZU)
4152

4253
2. **Next to the Post File**
4354

44-
Place your images next to the post file. For example, `plants.png` can be stored next to the `index.md` file in the `2024-01-20-how-it-works` folder:[![A closeup shop of plants](./plants.jpg 'A photo by Nahil Naseer')](https://unsplash.com/photos/green-leaf-plants-xljtGZ2-P3Y)
55+
Place your images next to the post file. For example, `plants.png` can be stored next to the `index.md` file in the `2024-01-20-how-it-works` folder:[![A closeup shop of plants](./plants.jpg "A photo by Nahil Naseer")](https://unsplash.com/photos/green-leaf-plants-xljtGZ2-P3Y)
4556

4657
## Truncate
4758

@@ -51,26 +62,30 @@ Limit the size of your blog posts in the list view using a `<!-- truncate -->` c
5162

5263
## React components
5364

54-
Docusaurus supports interactive components as part of the post's content. For example, if you insert this code block in Dhub's **embedded MDX** component:
65+
Dhub supports interactive components as part of the post's content. For example, if you insert this code block in Dhub's **embedded MDX** component:
5566

5667
```js
57-
<button onClick={() => alert('button clicked!')}>Click me!</button>Tags
68+
<button onClick={() => alert('You clicked me!')}>Click me!</button>Tags
5869
```
5970
6071
In the published site, it will show this element:
6172
6273
```mdx-code-block
63-
<button onClick={() => alert('button clicked!')}>Click me!</button>
74+
<button onClick={() => alert('You clicked me!')}>Click me!</button>
6475
```
6576

6677
## Tags
6778

68-
Tagging system enhances the organization of your posts, making it easy for readers to explore content based on their interests.
79+
Tagging let's you organize blog posts into categories. This makes it easy for readers to explore content based on their interests.
6980

70-
Create new tags by adding them as _frontmatter variables_ at the start of the file:
81+
To create new tags, add them as _frontmatter variables_ at the start of the file:
7182

7283
```
84+
---
7385
tags: [tag 1, tag 2, tag 3]
86+
---
87+
88+
## The content of the page starts here
7489
```
7590

7691
## Authors
@@ -79,8 +94,14 @@ Understand how authors are managed through the `blog/authors.yml` file, ensuring
7994

8095
:::note
8196

82-
At the moment, Dhub editor doesn't support opening this file; it has to be configured outside the Dhub editor.
97+
Editing this file in Dhub editor is coming soon!
8398

8499
:::
85100

86-
Learn about the `authors.yml` file structure at Docusaurus documentation: [Docusaurus Blog Documentation - Global Authors.](https://docusaurus.io/docs/blog#global-authors)
101+
To learn about the `authors.yml` file, see [Docusaurus documentation](https://docusaurus.io/docs/blog#global-authors)
102+
103+
:::tip
104+
105+
Need more hands-on assistance? Hop on our [Discord server](https://discord.gg/6qGnyrt7xy).
106+
107+
:::

blog/2024-01-21.md

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,60 +1,60 @@
11
---
22
slug: welcome
33
title: Welcome to Your Blog!
4-
authors: [ceo, arijus]
4+
authors: [val, arijus]
55
tags: [dhub, hello, docusaurus]
66
---
77

88
# **Welcome to Your Blog!**
99

10-
## Getting Started with Dhub and Docusaurus
10+
Greetings from Dhub the team! 👋
1111

12-
Greetings, blogger! 🚀 Welcome to Dhub, your all-in-one online editor designed for crafting beautiful blogs using the powerful Docusaurus framework.
12+
Welcome to [Dhub](https://dhub.dev), your all-in-one markdown editor for [Docusaurus](https://docusaurus.io/) framework.
1313

14-
## Navigating Your Blogging Space
14+
We are thrilled to have you on board and can't wait to see the amazing content you create!
1515

16-
As you embark on your blogging adventure, this initial page serves as your welcome hub. Here, you can find essential information about Dhub, including helpful tips and guidelines to kickstart your blogging journey. The intuitive editor interface is designed to enhance your writing experience, making it both enjoyable and efficient.
16+
## 1 minute tutorial
1717

18-
## How to Use Dhub
18+
### Add content
1919

20-
1. **Add Components:**
20+
Type `/` to reveal a list of available components.
21+
Select one, like `Heading 1` or `Image` and it to the document.
2122

22-
- Type "/" in the editor to reveal a list of available Docusaurus components.
23+
### Create a New Blog Post
2324

24-
- Select the desired component to add it to your blog post.
25+
- Click **"•••"** on the **"blog"** folder in the sidebar and choose **"New file..."**.
26+
- Give it a name like a date of the post like `2024-05-01` and hit enter. Dhub will add `.mdx` suffix automatically.
2527

26-
2. **Editing Made Easy:**
28+
![](/img/tutorial.jpg)
2729

28-
- Click on any component to modify its content.
30+
:::tip
2931

30-
- Utilize the toolbar for additional [_formatting_](#) options.
32+
Dhub supports both `.md` and `.mdx` although `.mdx` is more versatile.
3133

32-
3. **Create New Blog Posts:**
34+
:::
3335

34-
- Click **"•••"** on the **"blog"** folder in the sidebar to open a contextual menu.
36+
### Push to Github
3537

36-
- Choose **"New file..."** to create a new page.
38+
Hit the "Push to Github" at the top right.
3739

38-
- Give it a name and hit enter. If the file format isn't specified, Dhub will create a .mdx file.
40+
Dhub automates all the necessary steps to put your content on GitHub. No need to learn `git`.
3941

40-
- Dhub supports .md and .mdx files.![](/img/tutorial.jpg)
42+
### Publish on the web
4143

42-
4. **Push to Github:**
44+
For publishing, we recommend using external platforms like [Vercel](https://vercel.com/) or [Netlify](https://www.netlify.com/). They seamlessly integrate with Docusaurus.
4345

44-
- Hit the "Push to Github" button to store your changes outside Dhub.
46+
You can publish to Vercel right from Dhub.
4547

46-
5. **Publish your blog:**
48+
## What's next
4749

48-
- For publishing, we recommend using external platforms like [Netlify](https://www.netlify.com/) or [Vercel](https://vercel.com/), which seamlessly integrate with Docusaurus.
50+
Jump to **[2024-01-20-how-it-works](2024-01-20-how-it-works/index.mdx)** file to learn the best practices.
4951

50-
## Understanding Docusaurus
52+
Dhub is here to support your blogging and documentation journey every step of the way.
5153

52-
Dhub harnesses the capabilities of Docusaurus, a modern open-source documentation framework by Facebook. It enables you to build and maintain a clean, organized, and feature-rich blog with ease.
54+
Happy blogging!
5355

54-
:::note Learn more
56+
:::tip
5557

56-
Go to **"[2024-01-20-how-it-works.md](2024-01-20-how-it-works/index.mdx)"** file to learn the best practices using Docusaurus.
58+
Need more hands-on assistance? Hop on our [Discord server](https://discord.gg/6qGnyrt7xy).
5759

5860
:::
59-
60-
Remember, your creativity knows no bounds, and Dhub is here to support your blogging journey every step of the way. Happy blogging!

blog/authors.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
ceo:
1+
val:
22
name: Val Repšys
33
title: CEO @ Dhub
4-
url: https://github.com/vrepsys
4+
url: https://dhub.dev/
55
image_url: https://avatars.githubusercontent.com/u/1429012
66

77
arijus:
88
name: Arijus Šukys
9-
title: Super Engineer @ Dhub
10-
url: https://github.com/argshook
9+
title: Engineer @ Dhub
10+
url: https://dhub.dev/
1111
image_url: https://avatars.githubusercontent.com/u/4284659
1212

13-
personX:
13+
wonderful-person:
1414
name: A wonderful person
15-
title: First Dhub customer
16-
image_url: https://images.unsplash.com/photo-1588080064985-cb6ae38645bc?q=80&w=2500&auto=format&fit=crop&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D
15+
title: That's you!
16+
image_url: https://images.unsplash.com/photo-1588080064985-cb6ae38645bc?q=80&w=2500&auto=format&fit=crop&ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D

docusaurus.config.js

Lines changed: 26 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ import { themes as prismThemes } from "prism-react-renderer";
88

99
/** @type {import('@docusaurus/types').Config} */
1010
const config = {
11-
title: "Exploring the Digital Frontier",
12-
tagline: "A Comprehensive Journey into Docusaurus Documentation",
11+
title: "Your docs with Dhub",
12+
tagline: "Collaborative WYSIWYG editor for your Docusarus site",
1313
favicon: "img/favicon.ico",
1414

1515
// Set the production url of your site here
@@ -20,10 +20,10 @@ const config = {
2020

2121
// GitHub pages deployment config.
2222
// If you aren't using GitHub pages, you don't need these.
23-
organizationName: "facebook", // Usually your GitHub org/user name.
24-
projectName: "docusaurus", // Usually your repo name.
23+
organizationName: "dhub-dev", // Usually your GitHub org/user name.
24+
projectName: "template-docusaurus", // Usually your repo name.
2525

26-
onBrokenLinks: "throw",
26+
onBrokenLinks: "warn",
2727
onBrokenMarkdownLinks: "warn",
2828

2929
// Even if you don't use internationalization, you can use this field to set
@@ -43,15 +43,13 @@ const config = {
4343
sidebarPath: "./sidebars.js",
4444
// Please change this to your repo.
4545
// Remove this to remove the "edit this page" links.
46-
editUrl:
47-
"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/",
46+
editUrl: "https://github.com/dhub-dev/template-docusaurus/tree/main",
4847
},
4948
blog: {
5049
showReadingTime: true,
5150
// Please change this to your repo.
5251
// Remove this to remove the "edit this page" links.
53-
editUrl:
54-
"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/",
52+
editUrl: "https://github.com/dhub-dev/template-docusaurus/tree/main",
5553
},
5654
theme: {
5755
customCss: "./src/css/custom.css",
@@ -75,74 +73,58 @@ const config = {
7573
label: "Docs",
7674
},
7775
{ to: "/blog", label: "Blog", position: "left" },
78-
{ to: "/about-page", label: "About", position: "left" },
76+
{ to: "/about", label: "About", position: "left" },
7977
],
8078
},
8179
footer: {
8280
style: "light",
8381
links: [
8482
{
85-
title: "Docusaurus Community",
8683
items: [
8784
{
88-
label: "Stack Overflow",
89-
href: "https://stackoverflow.com/questions/tagged/docusaurus",
90-
},
91-
{
92-
label: "Discord",
93-
href: "https://discordapp.com/invite/docusaurus",
85+
label: "Documentation",
86+
href: "/docs",
9487
},
9588
{
96-
label: "Twitter",
97-
href: "https://twitter.com/docusaurus",
98-
},
99-
],
100-
},
101-
{
102-
title: "Docusaurus Resources",
103-
items: [
104-
{
105-
label: "Documentation",
106-
href: "https://docusaurus.io/docs/blog",
89+
label: "Blog",
90+
href: "/blog",
10791
},
10892
{
109-
label: "GitHub",
110-
href: "https://github.com/facebook/docusaurus",
93+
label: "About",
94+
href: "/about",
11195
},
11296
],
11397
},
98+
11499
{
115-
title: "Dhub Resources",
100+
title: "Dhub",
116101
items: [
117102
{
118-
label: "Application",
103+
label: "App",
119104
href: "https://dhub.dev",
120105
},
121106
{
122-
label: "Documentation",
123-
href: "https://docs.dhub.dev",
107+
label: "Website",
108+
href: "https://dhub.dev",
124109
},
125110
],
126111
},
112+
127113
{
128-
title: "Site links",
114+
title: "Support",
129115
items: [
130116
{
131-
label: "Documentation",
132-
href: "/docs",
133-
},
134-
{
135-
label: "Blog",
136-
href: "/blog",
117+
label: "Discord",
118+
href: "https://discord.gg/6qGnyrt7xy",
137119
},
138120
{
139-
label: "About",
140-
href: "/about-page",
121+
label: "GitHub",
122+
href: "https://github.com/dhub-dev",
141123
},
142124
],
143125
},
144126
],
145-
copyright: `Copyright © ${new Date().getFullYear()} Blog Website, Inc. Built with Docusaurus, edited with Dhub`,
127+
copyright: `Copyright © ${new Date().getFullYear()} Blog Website, Inc. Edited with Dhub on Docusaurus`,
146128
},
147129
prism: {
148130
theme: prismThemes.github,

0 commit comments

Comments
 (0)