Skip to content
Barrie Byron edited this page Jan 30, 2024 · 7 revisions

Links

Use short descriptive link text that helps provide context for the material that you're linking to.

Tip: Do not use "here" as link text.

Links to external URLs

For example, follow these examples that link to external URLs:

  • The zkApp CLI makes it easy to follow recommended best practices by providing project scaffolding, including dependencies such as o1js, a test framework Jest, code auto-formatting Prettier, linting ES Lint, and more.

Syntax for linking to other doc pages

You can link to specific headings on the same or different page and link to other doc pages.

Links to internal URLs

Markdown links work in different ways on our docs site. Although you can use a relative path, the preferred syntax is to use the file path after the base docs site URL, which simplifies maintenance.

For links to other headings on the same docs page:

  1. If your doc is not yet published, you can still form links. See How to see your local doc updates during development for steps to build the docs locally so you can test the doc build and see local updates before you push changes to GitHub.

  2. Local doc builds resolve to http://localhost:3000/.

For example, a local doc build URL for a specific heading on a page is http://localhost:3000/zkapps/how-zkapps-work#prover-function-and-verification-key.

  1. To form the link syntax, copy the link link URL after http://localhost:3000/.

For internal links to other pages on the docs site:

  1. Select the heading on the docs page to display the direct link in the web browser address bar.

  2. Copy the link after https://docs.minaprotocol.com/.

These examples use the shortened internal URL for linking to other doc pages:

GitHub

For links from files in the /docs2 repo to files in the /docs2 repo, you can use the shortened file path after the base docs site URL:

Links in README files

README files are an exception to using a shortened file path after the base docs site URL.

Because README files populate the npm package, you must use full, absolute links so that the links work on npm.

For example, the o1js README uses absolute links so that the links on the o1js npm package resolve correctly.

Clone this wiki locally