Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
f0bfe6ed
Commit
f0bfe6ed
authored
Jan 28, 2020
by
Marcia Ramos
Committed by
Achilleas Pipinellis
Jan 28, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Docs: update docs style guide for headings and anchors
parent
8a6f3a28
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
0 deletions
+29
-0
doc/development/documentation/styleguide.md
doc/development/documentation/styleguide.md
+29
-0
No files found.
doc/development/documentation/styleguide.md
View file @
f0bfe6ed
...
@@ -525,6 +525,35 @@ For other punctuation rules, please refer to the
...
@@ -525,6 +525,35 @@ For other punctuation rules, please refer to the
-
Use sentence case in headings. Do not capitalize the words of the title, unless
-
Use sentence case in headings. Do not capitalize the words of the title, unless
it refers to a product feature. For example, capitalizing "issues" is acceptable in
it refers to a product feature. For example, capitalizing "issues" is acceptable in
`## What you can do with GitLab Issues`
, but not in
`## Closing multiple issues`
.
`## What you can do with GitLab Issues`
, but not in
`## Closing multiple issues`
.
-
Our docs site search engine prioritizes headings, therefore, make sure to write
headings that contextualize the subject and help to take the user to the right
document. For example,
`## Examples`
is a bad heading;
`## GitLab Pages examples`
is a better one. It's not an exact science, but please consider this carefully.
### Anchor links
Headings generate anchor links automatically when rendered.
`## This is an example`
generates the anchor
`#this-is-an-example`
.
Keep in mind that the GitLab UI links to a large number of docs and respective
anchor links to take the user to the right spot. Therefore, when you change a
heading, search
`doc/*`
,
`app/views/*`
, and
`ee/app/views/*`
for the old anchor
to make sure you're not breaking an anchor linked from other docs nor from the
GitLab UI. If you find the old anchor, make sure to replace it with the new one.
Important:
-
Avoid crosslinking docs to headings unless you need to link to a specific section
of the document. This will avoid breaking anchors in the future in case the heading
is changed.
-
If possible, avoid changing headings since they're not only linked internally.
There are various links to GitLab documentation on the internet, such as tutorials,
presentations, StackOverflow posts, and other sources.
-
Do not link to
`h1`
headings.
Note that, with Kramdown, it is possible to add a custom ID to an HTML element
with Markdown markup, but they
**do not**
work in GitLab's
`/help`
. Therefore,
do not use this option until further notice.
## Links
## Links
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment