@docubook/create 2.2.0 → 2.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/dist/app/docs/[[...slug]]/page.tsx +2 -5
- package/src/dist/app/layout.tsx +1 -3
- package/src/dist/app/page.tsx +2 -21
- package/src/dist/components/SearchModal.tsx +1 -1
- package/src/dist/components/context-popover.tsx +1 -1
- package/src/dist/components/docs-menu.tsx +2 -2
- package/src/dist/components/markdown/AccordionGroupMdx.tsx +1 -1
- package/src/dist/components/markdown/AccordionMdx.tsx +4 -4
- package/src/dist/components/markdown/CardMdx.tsx +4 -4
- package/src/dist/components/markdown/FileTreeMdx.tsx +4 -4
- package/src/dist/components/markdown/ImageMdx.tsx +1 -1
- package/src/dist/components/markdown/ReleaseMdx.tsx +1 -1
- package/src/dist/components/markdown/TooltipsMdx.tsx +1 -1
- package/src/dist/components/sublink.tsx +1 -1
- package/src/dist/docs/components/accordion-group.mdx +68 -0
- package/src/dist/docs/components/accordion.mdx +59 -0
- package/src/dist/docs/components/button.mdx +40 -0
- package/src/dist/docs/components/card-group.mdx +47 -0
- package/src/dist/docs/components/card.mdx +68 -0
- package/src/dist/docs/components/code-block.mdx +67 -0
- package/src/dist/docs/components/custom.mdx +38 -0
- package/src/dist/docs/components/file-tree.mdx +109 -0
- package/src/dist/docs/components/image.mdx +37 -0
- package/src/dist/docs/components/index.mdx +9 -0
- package/src/dist/docs/components/keyboard.mdx +117 -0
- package/src/dist/docs/components/link.mdx +34 -0
- package/src/dist/docs/components/note.mdx +44 -0
- package/src/dist/docs/components/release-note.mdx +114 -0
- package/src/dist/docs/components/stepper.mdx +45 -0
- package/src/dist/docs/components/tables.mdx +35 -0
- package/src/dist/docs/components/tabs.mdx +72 -0
- package/src/dist/docs/components/tooltips.mdx +22 -0
- package/src/dist/docs/components/youtube.mdx +23 -0
- package/src/dist/docs/getting-started/introduction.mdx +18 -0
- package/src/dist/docs/getting-started/quick-start-guide.mdx +60 -0
- package/src/dist/docu.json +36 -38
- package/src/dist/eslint.config.mjs +17 -30
- package/src/dist/lib/markdown.ts +32 -17
- package/src/dist/lib/utils.ts +1 -1
- package/src/dist/next.config.mjs +10 -11
- package/src/dist/package.json +1 -1
- package/src/dist/contents/docs/api-reference/delete/index.mdx +0 -63
- package/src/dist/contents/docs/api-reference/fetch/index.mdx +0 -63
- package/src/dist/contents/docs/api-reference/get/index.mdx +0 -63
- package/src/dist/contents/docs/api-reference/post/index.mdx +0 -63
- package/src/dist/contents/docs/changelog/version-1/index.mdx +0 -49
- package/src/dist/contents/docs/changelog/version-2/index.mdx +0 -49
- package/src/dist/contents/docs/changelog/version-3/index.mdx +0 -49
- package/src/dist/contents/docs/getting-started/development/index.mdx +0 -92
- package/src/dist/contents/docs/getting-started/introduction/index.mdx +0 -92
- package/src/dist/contents/docs/getting-started/quick-start-guide/index.mdx +0 -92
- /package/src/dist/components/{contexts/AccordionContext.ts → AccordionContext.ts} +0 -0
- /package/src/dist/components/{contexts/theme-provider.tsx → theme-provider.tsx} +0 -0
- /package/src/dist/lib/{routes-config.ts → routes.ts} +0 -0
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
---
|
|
2
|
+
title : Quick Start Guide
|
|
3
|
+
description : a quick way to understand how to use it
|
|
4
|
+
date : 10-12-2024
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Adding a Route
|
|
8
|
+
|
|
9
|
+
To add a new page to your documentation, you need to register it in the `docu.json` file.
|
|
10
|
+
|
|
11
|
+
<Stepper>
|
|
12
|
+
<StepperItem title="Create the MDX file">
|
|
13
|
+
Create a new `.mdx` file in the `docs` directory. For example, `docs/my-new-page.mdx`.
|
|
14
|
+
</StepperItem>
|
|
15
|
+
<StepperItem title="Register in docu.json">
|
|
16
|
+
Open `docu.json` and add an entry to the `routes` array.
|
|
17
|
+
|
|
18
|
+
```json
|
|
19
|
+
{
|
|
20
|
+
"title": "My New Page",
|
|
21
|
+
"href": "/my-new-page"
|
|
22
|
+
}
|
|
23
|
+
```
|
|
24
|
+
</StepperItem>
|
|
25
|
+
</Stepper>
|
|
26
|
+
|
|
27
|
+
## Writing Content
|
|
28
|
+
|
|
29
|
+
DocuBook supports standard Markdown and a variety of custom components to make your documentation more interactive.
|
|
30
|
+
|
|
31
|
+
### Using Components
|
|
32
|
+
|
|
33
|
+
Here are some common components you can use:
|
|
34
|
+
|
|
35
|
+
#### Cards
|
|
36
|
+
|
|
37
|
+
Use cards to highlight important links or features.
|
|
38
|
+
|
|
39
|
+
<CardGroup cols={2}>
|
|
40
|
+
<Card title="Installation" icon="Download" href="#">
|
|
41
|
+
Learn how to install DocuBook.
|
|
42
|
+
</Card>
|
|
43
|
+
<Card title="Configuration" icon="Settings" href="#">
|
|
44
|
+
Configure your documentation site.
|
|
45
|
+
</Card>
|
|
46
|
+
</CardGroup>
|
|
47
|
+
|
|
48
|
+
#### Notes
|
|
49
|
+
|
|
50
|
+
Use notes to provide additional context or warnings.
|
|
51
|
+
|
|
52
|
+
<Note type="warning" title="Warning">
|
|
53
|
+
Always remember to back up your configuration files.
|
|
54
|
+
</Note>
|
|
55
|
+
|
|
56
|
+
<Note type="note" title="Pro Tip">
|
|
57
|
+
You can use Lucide icons in your cards by specifying the `icon` prop.
|
|
58
|
+
</Note>
|
|
59
|
+
|
|
60
|
+
For more details on available components, check out the [Components](/docs/components) section.
|
package/src/dist/docu.json
CHANGED
|
@@ -21,7 +21,7 @@
|
|
|
21
21
|
"repository": {
|
|
22
22
|
"url": "https://github.com/DocuBook/docubook",
|
|
23
23
|
"editPathTemplate": "/blob/main/{filePath}",
|
|
24
|
-
"editLink":
|
|
24
|
+
"editLink": false
|
|
25
25
|
},
|
|
26
26
|
"sponsor": {
|
|
27
27
|
"title": "Hosted on",
|
|
@@ -63,46 +63,44 @@
|
|
|
63
63
|
"href": "/getting-started",
|
|
64
64
|
"noLink": true,
|
|
65
65
|
"context": {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
},
|
|
70
|
-
"items": [
|
|
71
|
-
{ "title": "Introduction", "href": "/introduction" },
|
|
72
|
-
{ "title": "Quick Start Guide", "href": "/quick-start-guide" },
|
|
73
|
-
{ "title": "Development", "href": "/development" }
|
|
74
|
-
]
|
|
66
|
+
"icon": "Book",
|
|
67
|
+
"description": "Set up your Documentation",
|
|
68
|
+
"title": "Guides"
|
|
75
69
|
},
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
70
|
+
"items": [
|
|
71
|
+
{ "title": "Introduction", "href": "/introduction" },
|
|
72
|
+
{ "title": "Quick Start Guide", "href": "/quick-start-guide" }
|
|
73
|
+
]
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"title": "Components",
|
|
77
|
+
"href": "/components",
|
|
79
78
|
"noLink": true,
|
|
80
79
|
"context": {
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
},
|
|
85
|
-
"items": [
|
|
86
|
-
{ "title": "Get", "href": "/get" },
|
|
87
|
-
{ "title": "Fetch", "href": "/fetch" },
|
|
88
|
-
{ "title": "Post", "href": "/post" },
|
|
89
|
-
{ "title": "Delete", "href": "/delete" }
|
|
90
|
-
]
|
|
80
|
+
"icon": "Layers",
|
|
81
|
+
"description": "Write with Markdown",
|
|
82
|
+
"title": "Markdown"
|
|
91
83
|
},
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
84
|
+
"items": [
|
|
85
|
+
{ "title": "Accordion", "href": "/accordion" },
|
|
86
|
+
{ "title": "Accordion Group", "href": "/accordion-group" },
|
|
87
|
+
{ "title": "Button", "href": "/button" },
|
|
88
|
+
{ "title": "Card", "href": "/card" },
|
|
89
|
+
{ "title": "Card Group", "href": "/card-group" },
|
|
90
|
+
{ "title": "Code Block", "href": "/code-block" },
|
|
91
|
+
{ "title": "File Tree", "href": "/file-tree" },
|
|
92
|
+
{ "title": "Image", "href": "/image" },
|
|
93
|
+
{ "title": "Keyboard", "href": "/keyboard" },
|
|
94
|
+
{ "title": "Link", "href": "/link" },
|
|
95
|
+
{ "title": "Note", "href": "/note" },
|
|
96
|
+
{ "title": "Release Note", "href": "/release-note" },
|
|
97
|
+
{ "title": "Stepper", "href": "/stepper" },
|
|
98
|
+
{ "title": "Tabs", "href": "/tabs" },
|
|
99
|
+
{ "title": "Tooltips", "href": "/tooltips" },
|
|
100
|
+
{ "title": "Tables", "href": "/tables" },
|
|
101
|
+
{ "title": "Youtube", "href": "/youtube" },
|
|
102
|
+
{ "title": "Custom", "href": "/custom" }
|
|
103
|
+
]
|
|
104
|
+
}
|
|
107
105
|
]
|
|
108
106
|
}
|
|
@@ -1,35 +1,22 @@
|
|
|
1
|
-
import { defineConfig } from "eslint/config";
|
|
2
1
|
import nextCoreWebVitals from "eslint-config-next/core-web-vitals";
|
|
3
2
|
import nextTypescript from "eslint-config-next/typescript";
|
|
4
|
-
import path from "node:path";
|
|
5
|
-
import { fileURLToPath } from "node:url";
|
|
6
3
|
import js from "@eslint/js";
|
|
7
|
-
import
|
|
4
|
+
import tseslint from "typescript-eslint";
|
|
8
5
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
rules: {
|
|
25
|
-
"@typescript-eslint/no-explicit-any": "warn",
|
|
26
|
-
|
|
27
|
-
"@typescript-eslint/no-unused-vars": ["warn", {
|
|
28
|
-
argsIgnorePattern: "^_",
|
|
29
|
-
varsIgnorePattern: "^_",
|
|
30
|
-
caughtErrorsIgnorePattern: "^_",
|
|
31
|
-
}],
|
|
32
|
-
|
|
33
|
-
"@typescript-eslint/no-empty-object-type": "off",
|
|
6
|
+
export default tseslint.config(
|
|
7
|
+
js.configs.recommended,
|
|
8
|
+
...nextCoreWebVitals,
|
|
9
|
+
...nextTypescript,
|
|
10
|
+
...tseslint.configs["recommended"],
|
|
11
|
+
{
|
|
12
|
+
rules: {
|
|
13
|
+
"@typescript-eslint/no-explicit-any": "warn",
|
|
14
|
+
"@typescript-eslint/no-unused-vars": ["warn", {
|
|
15
|
+
argsIgnorePattern: "^_",
|
|
16
|
+
varsIgnorePattern: "^_",
|
|
17
|
+
caughtErrorsIgnorePattern: "^_",
|
|
18
|
+
}],
|
|
19
|
+
"@typescript-eslint/no-empty-object-type": "off",
|
|
20
|
+
},
|
|
34
21
|
},
|
|
35
|
-
|
|
22
|
+
);
|
package/src/dist/lib/markdown.ts
CHANGED
|
@@ -6,7 +6,7 @@ import rehypePrism from "rehype-prism-plus";
|
|
|
6
6
|
import rehypeAutolinkHeadings from "rehype-autolink-headings";
|
|
7
7
|
import rehypeSlug from "rehype-slug";
|
|
8
8
|
import rehypeCodeTitles from "rehype-code-titles";
|
|
9
|
-
import { page_routes, ROUTES } from "./routes
|
|
9
|
+
import { page_routes, ROUTES } from "./routes";
|
|
10
10
|
import { visit } from "unist-util-visit";
|
|
11
11
|
import type { Node, Parent } from "unist";
|
|
12
12
|
import matter from "gray-matter";
|
|
@@ -163,17 +163,20 @@ export type BaseMdxFrontmatter = {
|
|
|
163
163
|
|
|
164
164
|
export async function getDocsForSlug(slug: string) {
|
|
165
165
|
try {
|
|
166
|
-
const
|
|
167
|
-
const
|
|
168
|
-
return
|
|
166
|
+
const { content, filePath } = await getRawMdx(slug);
|
|
167
|
+
const mdx = await parseMdx<BaseMdxFrontmatter>(content);
|
|
168
|
+
return {
|
|
169
|
+
...mdx,
|
|
170
|
+
filePath,
|
|
171
|
+
};
|
|
169
172
|
} catch (err) {
|
|
170
173
|
console.log(err);
|
|
171
174
|
}
|
|
172
175
|
}
|
|
173
176
|
|
|
174
177
|
export async function getDocsTocs(slug: string) {
|
|
175
|
-
const
|
|
176
|
-
const rawMdx =
|
|
178
|
+
const { content } = await getRawMdx(slug);
|
|
179
|
+
const rawMdx = content;
|
|
177
180
|
|
|
178
181
|
// Regex to match code blocks (```...```), standard markdown headings (##), and <Release> tags
|
|
179
182
|
const combinedRegex = /(```[\s\S]*?```)|^(#{2,4})\s(.+)$|<Release[^>]*version="([^"]+)"/gm;
|
|
@@ -222,8 +225,26 @@ function sluggify(text: string) {
|
|
|
222
225
|
return slug.replace(/[^a-z0-9-]/g, "");
|
|
223
226
|
}
|
|
224
227
|
|
|
225
|
-
function
|
|
226
|
-
|
|
228
|
+
async function getRawMdx(slug: string) {
|
|
229
|
+
const commonPath = path.join(process.cwd(), "/docs/");
|
|
230
|
+
const paths = [
|
|
231
|
+
path.join(commonPath, `${slug}.mdx`),
|
|
232
|
+
path.join(commonPath, slug, "index.mdx"),
|
|
233
|
+
];
|
|
234
|
+
|
|
235
|
+
for (const p of paths) {
|
|
236
|
+
try {
|
|
237
|
+
const content = await fs.readFile(p, "utf-8");
|
|
238
|
+
return {
|
|
239
|
+
content,
|
|
240
|
+
filePath: `docs/${path.relative(commonPath, p)}`,
|
|
241
|
+
};
|
|
242
|
+
} catch {
|
|
243
|
+
// ignore and try next
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
throw new Error(`Could not find mdx file for slug: ${slug}`);
|
|
227
248
|
}
|
|
228
249
|
|
|
229
250
|
function justGetFrontmatterFromMD<Frontmatter>(rawMd: string): Frontmatter {
|
|
@@ -245,16 +266,10 @@ export async function getAllChilds(pathString: string) {
|
|
|
245
266
|
|
|
246
267
|
return await Promise.all(
|
|
247
268
|
page_routes_copy.map(async (it) => {
|
|
248
|
-
const
|
|
249
|
-
|
|
250
|
-
"/contents/docs/",
|
|
251
|
-
prevHref,
|
|
252
|
-
it.href,
|
|
253
|
-
"index.mdx"
|
|
254
|
-
);
|
|
255
|
-
const raw = await fs.readFile(totalPath, "utf-8");
|
|
269
|
+
const slug = path.join(prevHref, it.href);
|
|
270
|
+
const { content } = await getRawMdx(slug);
|
|
256
271
|
return {
|
|
257
|
-
...justGetFrontmatterFromMD<BaseMdxFrontmatter>(
|
|
272
|
+
...justGetFrontmatterFromMD<BaseMdxFrontmatter>(content),
|
|
258
273
|
href: `/docs${prevHref}${it.href}`,
|
|
259
274
|
};
|
|
260
275
|
})
|
package/src/dist/lib/utils.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type ClassValue, clsx } from "clsx";
|
|
2
2
|
import { twMerge } from "tailwind-merge";
|
|
3
|
-
import { EachRoute, ROUTES } from "./routes
|
|
3
|
+
import { EachRoute, ROUTES } from "./routes";
|
|
4
4
|
|
|
5
5
|
export function cn(...inputs: ClassValue[]) {
|
|
6
6
|
return twMerge(clsx(inputs));
|
package/src/dist/next.config.mjs
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
/** @type {import('next').NextConfig} */
|
|
2
2
|
const nextConfig = {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
export default nextConfig;
|
|
3
|
+
images: {
|
|
4
|
+
remotePatterns: [
|
|
5
|
+
{
|
|
6
|
+
protocol: "https",
|
|
7
|
+
hostname: "**",
|
|
8
|
+
},
|
|
9
|
+
],
|
|
10
|
+
},
|
|
11
|
+
}
|
|
14
12
|
|
|
13
|
+
export default nextConfig
|
package/src/dist/package.json
CHANGED
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title : Delete
|
|
3
|
-
description : example api DELETE
|
|
4
|
-
date : 10-12-2024
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Heading 2
|
|
8
|
-
|
|
9
|
-
this is regular text written in markdown format with `inline code`, **bold**, and *italic*
|
|
10
|
-
|
|
11
|
-
### Heading 3
|
|
12
|
-
|
|
13
|
-
example of ordered list format :
|
|
14
|
-
|
|
15
|
-
- list one
|
|
16
|
-
- sub list
|
|
17
|
-
- list two
|
|
18
|
-
- list three
|
|
19
|
-
|
|
20
|
-
#### Heading 4
|
|
21
|
-
|
|
22
|
-
Below is an example of how to write a code block :
|
|
23
|
-
|
|
24
|
-
````plaintext
|
|
25
|
-
```javascript:main.js showLineNumbers {3-4}
|
|
26
|
-
function isRocketAboutToCrash() {
|
|
27
|
-
// Check if the rocket is stable
|
|
28
|
-
if (!isStable()) {
|
|
29
|
-
NoCrash(); // Prevent the crash
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
```
|
|
33
|
-
````
|
|
34
|
-
|
|
35
|
-
example note :
|
|
36
|
-
```plaintext
|
|
37
|
-
<Note type="note" title="Note">
|
|
38
|
-
This is a general note to convey information to the user.
|
|
39
|
-
</Note>
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
displaying an image in markdown format :
|
|
43
|
-
|
|
44
|
-
```plaintext
|
|
45
|
-

|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
render as :
|
|
49
|
-

|
|
50
|
-
|
|
51
|
-
For a complete guide on using markdown content in DocuBook, please refer to the [Components](https://docubook.pro/docs/components) page.
|
|
52
|
-
|
|
53
|
-
<Note type="warning" title="Warning">
|
|
54
|
-
every page that is indexed in a folder will have an `index.mdx` file with metadata :
|
|
55
|
-
```plaintext
|
|
56
|
-
---
|
|
57
|
-
title : Introduction
|
|
58
|
-
description : overview or synopsis of a project
|
|
59
|
-
date : 10-12-2024
|
|
60
|
-
image : example-img.png
|
|
61
|
-
---
|
|
62
|
-
```
|
|
63
|
-
</Note>
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title : Fetch
|
|
3
|
-
description : example api FETCH
|
|
4
|
-
date : 10-12-2024
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Heading 2
|
|
8
|
-
|
|
9
|
-
this is regular text written in markdown format with `inline code`, **bold**, and *italic*
|
|
10
|
-
|
|
11
|
-
### Heading 3
|
|
12
|
-
|
|
13
|
-
example of ordered list format :
|
|
14
|
-
|
|
15
|
-
- list one
|
|
16
|
-
- sub list
|
|
17
|
-
- list two
|
|
18
|
-
- list three
|
|
19
|
-
|
|
20
|
-
#### Heading 4
|
|
21
|
-
|
|
22
|
-
Below is an example of how to write a code block :
|
|
23
|
-
|
|
24
|
-
````plaintext
|
|
25
|
-
```javascript:main.js showLineNumbers {3-4}
|
|
26
|
-
function isRocketAboutToCrash() {
|
|
27
|
-
// Check if the rocket is stable
|
|
28
|
-
if (!isStable()) {
|
|
29
|
-
NoCrash(); // Prevent the crash
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
```
|
|
33
|
-
````
|
|
34
|
-
|
|
35
|
-
example note :
|
|
36
|
-
```plaintext
|
|
37
|
-
<Note type="note" title="Note">
|
|
38
|
-
This is a general note to convey information to the user.
|
|
39
|
-
</Note>
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
displaying an image in markdown format :
|
|
43
|
-
|
|
44
|
-
```plaintext
|
|
45
|
-

|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
render as :
|
|
49
|
-

|
|
50
|
-
|
|
51
|
-
For a complete guide on using markdown content in DocuBook, please refer to the [Components](https://docubook.pro/docs/components) page.
|
|
52
|
-
|
|
53
|
-
<Note type="warning" title="Warning">
|
|
54
|
-
every page that is indexed in a folder will have an `index.mdx` file with metadata :
|
|
55
|
-
```plaintext
|
|
56
|
-
---
|
|
57
|
-
title : Introduction
|
|
58
|
-
description : overview or synopsis of a project
|
|
59
|
-
date : 10-12-2024
|
|
60
|
-
image : example-img.png
|
|
61
|
-
---
|
|
62
|
-
```
|
|
63
|
-
</Note>
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title : Get
|
|
3
|
-
description : example api GET
|
|
4
|
-
date : 10-12-2024
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Heading 2
|
|
8
|
-
|
|
9
|
-
this is regular text written in markdown format with `inline code`, **bold**, and *italic*
|
|
10
|
-
|
|
11
|
-
### Heading 3
|
|
12
|
-
|
|
13
|
-
example of ordered list format :
|
|
14
|
-
|
|
15
|
-
- list one
|
|
16
|
-
- sub list
|
|
17
|
-
- list two
|
|
18
|
-
- list three
|
|
19
|
-
|
|
20
|
-
#### Heading 4
|
|
21
|
-
|
|
22
|
-
Below is an example of how to write a code block :
|
|
23
|
-
|
|
24
|
-
````plaintext
|
|
25
|
-
```javascript:main.js showLineNumbers {3-4}
|
|
26
|
-
function isRocketAboutToCrash() {
|
|
27
|
-
// Check if the rocket is stable
|
|
28
|
-
if (!isStable()) {
|
|
29
|
-
NoCrash(); // Prevent the crash
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
```
|
|
33
|
-
````
|
|
34
|
-
|
|
35
|
-
example note :
|
|
36
|
-
```plaintext
|
|
37
|
-
<Note type="note" title="Note">
|
|
38
|
-
This is a general note to convey information to the user.
|
|
39
|
-
</Note>
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
displaying an image in markdown format :
|
|
43
|
-
|
|
44
|
-
```plaintext
|
|
45
|
-

|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
render as :
|
|
49
|
-

|
|
50
|
-
|
|
51
|
-
For a complete guide on using markdown content in DocuBook, please refer to the [Components](https://docubook.pro/docs/components) page.
|
|
52
|
-
|
|
53
|
-
<Note type="warning" title="Warning">
|
|
54
|
-
every page that is indexed in a folder will have an `index.mdx` file with metadata :
|
|
55
|
-
```plaintext
|
|
56
|
-
---
|
|
57
|
-
title : Introduction
|
|
58
|
-
description : overview or synopsis of a project
|
|
59
|
-
date : 10-12-2024
|
|
60
|
-
image : example-img.png
|
|
61
|
-
---
|
|
62
|
-
```
|
|
63
|
-
</Note>
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title : Post
|
|
3
|
-
description : example api POST
|
|
4
|
-
date : 10-12-2024
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Heading 2
|
|
8
|
-
|
|
9
|
-
this is regular text written in markdown format with `inline code`, **bold**, and *italic*
|
|
10
|
-
|
|
11
|
-
### Heading 3
|
|
12
|
-
|
|
13
|
-
example of ordered list format :
|
|
14
|
-
|
|
15
|
-
- list one
|
|
16
|
-
- sub list
|
|
17
|
-
- list two
|
|
18
|
-
- list three
|
|
19
|
-
|
|
20
|
-
#### Heading 4
|
|
21
|
-
|
|
22
|
-
Below is an example of how to write a code block :
|
|
23
|
-
|
|
24
|
-
````plaintext
|
|
25
|
-
```javascript:main.js showLineNumbers {3-4}
|
|
26
|
-
function isRocketAboutToCrash() {
|
|
27
|
-
// Check if the rocket is stable
|
|
28
|
-
if (!isStable()) {
|
|
29
|
-
NoCrash(); // Prevent the crash
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
```
|
|
33
|
-
````
|
|
34
|
-
|
|
35
|
-
example note :
|
|
36
|
-
```plaintext
|
|
37
|
-
<Note type="note" title="Note">
|
|
38
|
-
This is a general note to convey information to the user.
|
|
39
|
-
</Note>
|
|
40
|
-
```
|
|
41
|
-
|
|
42
|
-
displaying an image in markdown format :
|
|
43
|
-
|
|
44
|
-
```plaintext
|
|
45
|
-

|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
render as :
|
|
49
|
-

|
|
50
|
-
|
|
51
|
-
For a complete guide on using markdown content in DocuBook, please refer to the [Components](https://docubook.pro/docs/components) page.
|
|
52
|
-
|
|
53
|
-
<Note type="warning" title="Warning">
|
|
54
|
-
every page that is indexed in a folder will have an `index.mdx` file with metadata :
|
|
55
|
-
```plaintext
|
|
56
|
-
---
|
|
57
|
-
title : Introduction
|
|
58
|
-
description : overview or synopsis of a project
|
|
59
|
-
date : 10-12-2024
|
|
60
|
-
image : example-img.png
|
|
61
|
-
---
|
|
62
|
-
```
|
|
63
|
-
</Note>
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title : Version 1
|
|
3
|
-
description : changelog version
|
|
4
|
-
date : 10-12-2024
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Render as
|
|
8
|
-
|
|
9
|
-
<Release version="1.0.0" date="2025-08-10" title="Release version 1.0.0">
|
|
10
|
-
<Changes type="added">
|
|
11
|
-
- add components
|
|
12
|
-
</Changes>
|
|
13
|
-
<Changes type="fixed">
|
|
14
|
-
- fix globals.css
|
|
15
|
-
</Changes>
|
|
16
|
-
<Changes type="improved">
|
|
17
|
-
- improved search components
|
|
18
|
-
</Changes>
|
|
19
|
-
<Changes type="deprecated">
|
|
20
|
-
- deprecated footer components
|
|
21
|
-
</Changes>
|
|
22
|
-
<Changes type="removed">
|
|
23
|
-
- removed utility class
|
|
24
|
-
- removed unused hooks
|
|
25
|
-
</Changes>
|
|
26
|
-
</Release>
|
|
27
|
-
|
|
28
|
-
## Output Markdown
|
|
29
|
-
|
|
30
|
-
```
|
|
31
|
-
<Release version="1.0.0" date="2025-08-10" title="Release version 1.0.0">
|
|
32
|
-
<Changes type="added">
|
|
33
|
-
- add components
|
|
34
|
-
</Changes>
|
|
35
|
-
<Changes type="fixed">
|
|
36
|
-
- fix globals.css
|
|
37
|
-
</Changes>
|
|
38
|
-
<Changes type="improved">
|
|
39
|
-
- improved search components
|
|
40
|
-
</Changes>
|
|
41
|
-
<Changes type="deprecated">
|
|
42
|
-
- deprecated footer components
|
|
43
|
-
</Changes>
|
|
44
|
-
<Changes type="removed">
|
|
45
|
-
- removed utility class
|
|
46
|
-
- removed unused hooks
|
|
47
|
-
</Changes>
|
|
48
|
-
</Release>
|
|
49
|
-
```
|
|
@@ -1,49 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title : Version 2
|
|
3
|
-
description : changelog version
|
|
4
|
-
date : 10-12-2024
|
|
5
|
-
---
|
|
6
|
-
|
|
7
|
-
## Render as
|
|
8
|
-
|
|
9
|
-
<Release version="2.0.0" date="2025-08-10" title="Release version 2.0.0">
|
|
10
|
-
<Changes type="added">
|
|
11
|
-
- add components
|
|
12
|
-
</Changes>
|
|
13
|
-
<Changes type="fixed">
|
|
14
|
-
- fix globals.css
|
|
15
|
-
</Changes>
|
|
16
|
-
<Changes type="improved">
|
|
17
|
-
- improved search components
|
|
18
|
-
</Changes>
|
|
19
|
-
<Changes type="deprecated">
|
|
20
|
-
- deprecated footer components
|
|
21
|
-
</Changes>
|
|
22
|
-
<Changes type="removed">
|
|
23
|
-
- removed utility class
|
|
24
|
-
- removed unused hooks
|
|
25
|
-
</Changes>
|
|
26
|
-
</Release>
|
|
27
|
-
|
|
28
|
-
## Output Markdown
|
|
29
|
-
|
|
30
|
-
```
|
|
31
|
-
<Release version="2.0.0" date="2025-08-10" title="Release version 2.0.0">
|
|
32
|
-
<Changes type="added">
|
|
33
|
-
- add components
|
|
34
|
-
</Changes>
|
|
35
|
-
<Changes type="fixed">
|
|
36
|
-
- fix globals.css
|
|
37
|
-
</Changes>
|
|
38
|
-
<Changes type="improved">
|
|
39
|
-
- improved search components
|
|
40
|
-
</Changes>
|
|
41
|
-
<Changes type="deprecated">
|
|
42
|
-
- deprecated footer components
|
|
43
|
-
</Changes>
|
|
44
|
-
<Changes type="removed">
|
|
45
|
-
- removed utility class
|
|
46
|
-
- removed unused hooks
|
|
47
|
-
</Changes>
|
|
48
|
-
</Release>
|
|
49
|
-
```
|