mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-10-12 18:49:37 +02:00
docs: contribute with vitepress
This commit is contained in:
@@ -67,31 +67,23 @@ flowchart LR
|
|||||||
|
|
||||||
### The official documentation site
|
### The official documentation site
|
||||||
|
|
||||||
**[The mermaid documentation site](https://mermaid-js.github.io/mermaid/) is powered by [Docsify](https://docsify.js.org), a simple documentation site generator.**
|
**[The mermaid documentation site](https://mermaid-js.github.io/mermaid/) is powered by [Vitepress](https://vitepress.vuejs.org/), a simple documentation site generator.**
|
||||||
|
|
||||||
If you want to preview the whole documentation site on your machine, you need to install `docsify-cli`:
|
If you want to preview the whole documentation site on your machine:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
$ npm i docsify-cli -g
|
$ cd mermaid
|
||||||
|
$ pnpm i
|
||||||
|
$ pnpm docs:dev
|
||||||
```
|
```
|
||||||
|
|
||||||
If you are more familiar with Yarn, you can use the following command:
|
You can now build and serve the documentation site:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
$ yarn global add docsify-cli
|
$ pnpm docs:bundle
|
||||||
|
$ pnpm docs:serve
|
||||||
```
|
```
|
||||||
|
|
||||||
The above command will install `docsify-cli` globally.
|
|
||||||
If the installation is successful, the command `docsify` will be available in your `PATH`.
|
|
||||||
|
|
||||||
You can now run the following command to serve the documentation site:
|
|
||||||
|
|
||||||
```sh
|
|
||||||
$ docsify serve docs
|
|
||||||
```
|
|
||||||
|
|
||||||
Once the local HTTP server is listening, you can point your browser at http://localhost:3000.
|
|
||||||
|
|
||||||
## Branching
|
## Branching
|
||||||
|
|
||||||
Going forward we will use a git flow inspired approach to branching. So development is done in develop, to do the development in the develop.
|
Going forward we will use a git flow inspired approach to branching. So development is done in develop, to do the development in the develop.
|
||||||
@@ -152,7 +144,7 @@ The source files for documentation are in `/packages/mermaid/src/docs` and are w
|
|||||||
|
|
||||||
#### Adding to or changing the documentation organization
|
#### Adding to or changing the documentation organization
|
||||||
|
|
||||||
If you want to add a new section or change the organization (structure), then you need to make sure to **change the side navigation** in `docs/_sidebar.md`.
|
If you want to add a new section or change the organization (structure), then you need to make sure to **change the side navigation** in `mermaid/src/docs/.vitepress/config.js`.
|
||||||
|
|
||||||
When changes are committed and then released, they become part of the `master` branch and become part of the published documentation on https://mermaid-js.github.io/mermaid/
|
When changes are committed and then released, they become part of the `master` branch and become part of the published documentation on https://mermaid-js.github.io/mermaid/
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user