Skip to content

jkowalcz/docs

 
 

Repository files navigation

Helium Documentation

Documentation for the Helium network.

Requirements

Installation

Contributing

Documentation is managed by Helium, but supported by the community.

Please see CONTRIBUTING.md for more instructions.

Creating a New Doc

When authoring a new doc, be sure to apply prettier to it during review. For example: npx prettier --write --prose-wrap always docs/blockchain/new_doc.mdx

It will apply appropriate line wraps and other formatting niceties.

Editing an Existing Doc

When editing an existing doc, line wrap should not be applied (don't run prettier), and lines that run wider than 80 chars in width are okay. Applying prettier would cause many unimportant line changes and make review more difficult.

Instead, from time to time, prettier will be run against the documents and those unimportant commits will be added to .git-blame-ignore-revs

Use the style guide found here to learn what markdown syntax is available.

For more advanced content consider using JSX.

Linking to Other Docs

When linking to other docs always use full path links or abbreviated links to full path links at the bottom of the doc. Abbreviated links help improve readability of the raw markdown and makes common links reusable in the same doc.

Abbreviated Links Example:
If you would like to link to the development devices introduction page found at /use-the-network/devices/development, use [development devices][devices.development] inline with your text content. Next, create the link to the full path at the very bottom of the doc markdown like this [devices.development]: /use-the-network/devices/development.

Adding Images

When adding images, use the method shown below.

---
id: my-doc
title: My Doc
---

# Doc Title

// Add to the top of the file below the front matter and title.
import useBaseUrl from '@docusaurus/useBaseUrl';

...

<img alt="Image Description" src={useBaseUrl('img/image.svg')} />

Image Naming

When naming images with multiple words, use - to separate the words only.

Adding a New Doc

Create a new *.mdx extension file following the existing naming conventions.

Doc Front Matter

When creating a new doc, use the following front matter at the very top of the doc with the following fields:

id: This should match the filename without the extension.
title: The title of your document. If this field is not present, the document's title will default to its id.
description: The description of your document.
sidebar_label: This should match id name but with spaces and capitalized first letters.

---
id: devices
title: Devices
description: Learn about Helium Devices
sidebar_label: Devices
---

slug: If the doc id path has repeated sections like the following doc path use-the-network/devices/devices, define a slug: field in the front matter to make it pretty as shown below. This way when this doc is navigated to, the URL shown will not have repeating sections names in it.

slug: use-the-network/devices

Check for dead links

yarn build does a good job of checking for dead links.

TODO: add to CI

Sidebar Links

Learn how to create sidebar links here.

Category Type

When adding items use the raw id path, slug paths will not work.

Attribution

This website is built using Docusaurus 2, a modern static website generator.

About

Helium Documentation

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 79.0%
  • CSS 21.0%