Skip to content

Commit 4ebd85d

Browse files
feat(docs): set up base docs package
1 parent 5ec969a commit 4ebd85d

23 files changed

+10407
-0
lines changed

docs/.gitignore

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Dependencies
2+
/node_modules
3+
4+
# Production
5+
/build
6+
7+
# Generated files
8+
.docusaurus
9+
.cache-loader
10+
11+
# Misc
12+
.DS_Store
13+
.env.local
14+
.env.development.local
15+
.env.test.local
16+
.env.production.local
17+
18+
npm-debug.log*
19+
yarn-debug.log*
20+
yarn-error.log*

docs/.nvmrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
v18

docs/README.md

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Website
2+
3+
This website is built using [Docusaurus](https://docusaurus.io/), a modern static website generator.
4+
5+
### Installation
6+
7+
```
8+
$ yarn
9+
```
10+
11+
### Local Development
12+
13+
```
14+
$ yarn start
15+
```
16+
17+
This command starts a local development server and opens up a browser window. Most changes are reflected live without having to restart the server.
18+
19+
### Build
20+
21+
```
22+
$ yarn build
23+
```
24+
25+
This command generates static content into the `build` directory and can be served using any static contents hosting service.
26+
27+
### Deployment
28+
29+
Using SSH:
30+
31+
```
32+
$ USE_SSH=true yarn deploy
33+
```
34+
35+
Not using SSH:
36+
37+
```
38+
$ GIT_USER=<Your GitHub username> yarn deploy
39+
```
40+
41+
If you are using GitHub pages for hosting, this command is a convenient way to build the website and push to the `gh-pages` branch.

docs/docs/intro.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
sidebar_position: 1
3+
---
4+
5+
# Introduction
6+
7+
Here you can find the documentation for the packages of the XRPL Go project.

docs/docs/packages/_category_.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"label": "Packages",
3+
"position": 2,
4+
"link": {
5+
"type": "generated-index",
6+
"description": "Packages of the XRPL Go project."
7+
}
8+
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
sidebar_position: 2
3+
---
4+

docs/docs/packages/binary-codec.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
---
2+
sidebar_position: 1
3+
---

docs/docs/packages/keypairs.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
---
2+
sidebar_position: 3
3+
---

docs/docs/packages/xrpl.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
---
2+
sidebar_position: 4
3+
---

docs/docusaurus.config.ts

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
import {themes as prismThemes} from 'prism-react-renderer';
2+
import type {Config} from '@docusaurus/types';
3+
import type * as Preset from '@docusaurus/preset-classic';
4+
5+
// This runs in Node.js - Don't use client-side code here (browser APIs, JSX...)
6+
7+
const config: Config = {
8+
title: 'XRPL Go',
9+
tagline: 'XRPL Go',
10+
favicon: 'img/favicon.ico',
11+
12+
// Set the production url of your site here
13+
url: 'https://your-docusaurus-site.example.com',
14+
// Set the /<baseUrl>/ pathname under which your site is served
15+
// For GitHub pages deployment, it is often '/<projectName>/'
16+
baseUrl: '/',
17+
18+
// GitHub pages deployment config.
19+
// If you aren't using GitHub pages, you don't need these.
20+
organizationName: 'Peersyst', // Usually your GitHub org/user name.
21+
projectName: 'xrpl-go', // Usually your repo name.
22+
23+
onBrokenLinks: 'throw',
24+
onBrokenMarkdownLinks: 'warn',
25+
26+
// Even if you don't use internationalization, you can use this field to set
27+
// useful metadata like html lang. For example, if your site is Chinese, you
28+
// may want to replace "en" with "zh-Hans".
29+
i18n: {
30+
defaultLocale: 'en',
31+
locales: ['en'],
32+
},
33+
34+
presets: [
35+
[
36+
'classic',
37+
{
38+
docs: {
39+
sidebarPath: './sidebars.ts',
40+
// Please change this to your repo.
41+
// Remove this to remove the "edit this page" links.
42+
editUrl:
43+
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
44+
},
45+
blog: {
46+
showReadingTime: true,
47+
feedOptions: {
48+
type: ['rss', 'atom'],
49+
xslt: true,
50+
},
51+
// Please change this to your repo.
52+
// Remove this to remove the "edit this page" links.
53+
editUrl:
54+
'https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/',
55+
// Useful options to enforce blogging best practices
56+
onInlineTags: 'warn',
57+
onInlineAuthors: 'warn',
58+
onUntruncatedBlogPosts: 'warn',
59+
},
60+
theme: {
61+
customCss: './src/css/custom.css',
62+
},
63+
} satisfies Preset.Options,
64+
],
65+
],
66+
67+
themeConfig: {
68+
// Replace with your project's social card
69+
image: 'img/logo.png',
70+
navbar: {
71+
title: 'XRPL Go',
72+
logo: {
73+
alt: 'XRPL Go Logo',
74+
src: 'img/xrpl-logo.png',
75+
},
76+
items: [
77+
{
78+
type: 'docSidebar',
79+
sidebarId: 'tutorialSidebar',
80+
position: 'left',
81+
label: 'Docs',
82+
},
83+
{
84+
href: 'https://github.com/Peersyst/xrpl-go',
85+
label: 'GitHub',
86+
position: 'right',
87+
},
88+
],
89+
},
90+
footer: {
91+
style: 'dark',
92+
links: [
93+
{
94+
title: 'Docs',
95+
items: [
96+
{
97+
label: 'Docs',
98+
to: '/docs/intro',
99+
},
100+
],
101+
},
102+
{
103+
title: 'More',
104+
items: [
105+
{
106+
label: 'GitHub',
107+
href: 'https://github.com/Peersyst/xrpl-go',
108+
},
109+
],
110+
},
111+
],
112+
copyright: `Copyright © ${new Date().getFullYear()} XRPL Go.`,
113+
},
114+
prism: {
115+
theme: prismThemes.github,
116+
darkTheme: prismThemes.dracula,
117+
},
118+
} satisfies Preset.ThemeConfig,
119+
};
120+
121+
export default config;

0 commit comments

Comments
 (0)