-
Notifications
You must be signed in to change notification settings - Fork 71
DOC Add info for links to docs and images for modules #780
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 6
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -192,12 +192,18 @@ Code for an Alert box: | |||||
|
||||||
### Links to documentation | ||||||
|
||||||
Links to other pages in the documentation uses the URL slug, *not* the file name. | ||||||
When updating documentation for [`silverstripe/developer-docs`](https://github.com/silverstripe/developer-docs/), which is the content repository for [`docs.silverstripe.org`](https://docs.silverstripe.org), links to other pages in the documentation should use the URL slug, not the file name. | ||||||
|
||||||
When updating docs that are in a modules `docs/en` folder, and will be shown in the "Optional features" section of `docs.silverstripe.org`, and are also intended to be readible on GitHub, then links to other pages should use a relative path to the file name, not the URL slug. | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also, put this note below the bits about "Relative documentation links" and "Absolute documentation links" below which are specific to docs in |
||||||
|
||||||
Relative documentation links are prefixed with `./` for pages in the same directory, or `../` for pages in parent directories. For example `[contributing code](./code)` becomes [contributing code](./code) and `[getting started](../getting_started)` becomes [getting started](../getting_started). | ||||||
|
||||||
Absolute documentation links are preferred for pages which aren't in the same directory or one level up. The language and version number are ommitted. For example `[managing lists](/developer_guides/model/lists/)` becomes [managing lists](/developer_guides/model/lists/). | ||||||
|
||||||
### Images | ||||||
|
||||||
Add images, such as screenshots, to an `_images` directory which should usually be located at `docs/en/_images`. Use relative links these files and use the markdown syntax ``. You must include alt text. Adding images this way will work correctly on both markdown added to `silverstripe/developer-docs`, and also to `docs/en` folder for a module that dispays on both `docs.silverstripe.org` and GitHub. | ||||||
|
||||||
### Links to API documentation | ||||||
|
||||||
API documentation is linked in a special way. Give some examples for classes, methods, properties. | ||||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.