Skip to content
This repository was archived by the owner on Apr 20, 2019. It is now read-only.

Commit 90924cf

Browse files
authored
Update CONTRIBUTING.md
1 parent afdfe0b commit 90924cf

File tree

1 file changed

+28
-21
lines changed

1 file changed

+28
-21
lines changed

CONTRIBUTING.md

Lines changed: 28 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,50 @@
11
# Contributing to the Blazor documentation
22

3-
This document covers the process for contributing to the articles and code samples that are hosted on the http://blazor.net. Contributions may be as simple as typo corrections or as complex as new articles.
3+
This document covers the process for contributing to the articles and code samples that are hosted at http://blazor.net. Contributions may be as simple as typo corrections or as complex as new articles.
44

55
## How to make a simple correction or suggestion
66

7-
Articles are stored in the repository as Markdown files. Simple changes to the content of a Markdown file can be made in the browser by selecting the **Improve this Doc** link in the upper right corner of the browser window, editing the doc on GitHub, and then submitting a pull request (PR) for the change. We will review the PR and accept it or suggest changes.
7+
Articles are stored in the repository as markdown files. Simple changes to the content of a markdown file can be made in the browser by selecting the **Improve this Doc** link in the upper-right corner of the browser window, editing the doc on GitHub, and then submitting a pull request (PR) for the change. We will review the PR and accept it or suggest changes.
88

99
## How to make a more complex submission
1010

1111
You'll need a basic understanding of [Git and GitHub.com](https://guides.github.com/activities/hello-world/).
1212

13-
* Open an [issue](https://github.com/aspnet/Blazor.Docs/issues/new) describing what you want to do, such as change an existing article or create a new one. Wait for approval from the team before you invest much time.
13+
* Open an [issue](https://github.com/aspnet/Blazor.Docs/issues/new) describing what you want to do, such as change an existing article or create a new one. Wait for approval from the team before you invest much time. We usually request an outline for a new topic proposal.
1414
* Fork the [aspnet/Blazor.Docs](https://github.com/aspnet/Blazor.Docs/) repo and create a branch for your changes.
1515
* Submit a pull request (PR) to master with your changes.
1616
* If your PR has the label 'cla-required' assigned, [complete the Contribution License Agreement (CLA)](https://cla.dotnetfoundation.org/)
1717
* Respond to PR feedback.
1818

1919
## Markdown syntax
2020

21-
Articles are written in [DocFx-flavored Markdown](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html), which is a superset of [GitHub-flavored Markdown (GFM)](https://guides.github.com/features/mastering-markdown/). For examples of DFM syntax for UI features commonly used in the Blazor documentation, see [Metadata and Markdown Template](https://github.com/dotnet/docs/blob/master/styleguide/template.md) in the .NET repo style guide.
21+
Articles are written in [DocFx-flavored Markdown (DFM)](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html), which is a superset of [GitHub-flavored Markdown (GFM)](https://guides.github.com/features/mastering-markdown/). For examples of DFM syntax for UI features commonly used in the Blazor documentation, see [Metadata and Markdown Template](https://github.com/dotnet/docs/blob/master/styleguide/template.md) in the .NET repo style guide.
2222

2323
## Folder structure conventions
2424

25-
For each Markdown file there may be a folder for images and a folder for sample code. For example, if the article is *tutorials/build-your-first-blazor-app.md*, the images are in *tutorials/build-your-first-blazor-app/\_static* and the sample application project files are in *tutorials/build-your-first-blazor-app/sample*. An image in the *tutorials/build-your-first-blazor-app.md* file is rendered by the following Markdown.
25+
For each markdown file, there may be a folder for images and a folder for sample code. For example, if the article is *tutorials/build-your-first-blazor-app.md*, the images are in *tutorials/build-your-first-blazor-app/\_static* and the sample app project files are in *tutorials/build-your-first-blazor-app/samples/2.x* (for a 2.x versioned sample). An image in the *tutorials/build-your-first-blazor-app.md* file is rendered by the following markdown.
2626

2727
```
28-
![description of image for alt attribute](tutorials/build-your-first-blazor-app/_static/imagename.png)
28+
![description of image for alt attribute](tutorials/build-your-first-blazor-app/_static/image-name.png)
2929
```
3030

3131
**All** images should have [alt text](https://wikipedia.org/wiki/Alt_attribute).
3232

33-
Markdown file names and image file names should be all lower case.
33+
Markdown file names and image file names should be all lower case. Use dashes to separate words in file names.
3434

3535
## Internal links
3636

3737
Internal links should use the `uid` of the target article with an xref link:
3838

39-
`[link_text](xref:uid_of_the_topic)`
39+
```
40+
[link_text](xref:uid_of_the_topic)
41+
```
4042

41-
See [DocFX Cross Reference](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html#cross-reference) for more info.
43+
For more informatin, see the [DocFX Cross Reference](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html#cross-reference).
4244

4345
## Code snippets
4446

45-
Articles frequently contain code snippets to illustrate points. DFM lets you copy code into the Markdown file or refer to a separate code file. We prefer to use separate code files whenever possible, to minimize the chance of errors in the code. The code files should be stored in the repo using the folder structure described above for sample projects.
47+
Articles frequently contain code snippets to illustrate points. DFM lets you copy code into the Markdown file or refer to a separate code file. We prefer to use separate code files whenever possible to minimize the chance of errors in the code. The code files should be stored in the repo using the folder structure described above for sample projects.
4648

4749
Here are some examples of [DFM code snippet syntax](http://dotnet.github.io/docfx/spec/docfx_flavored_markdown.html#code-snippet) that would be used in a *tutorials/build-your-first-blazor-app.md* file.
4850

@@ -59,7 +61,7 @@ To render a portion of a file as a snippet by using line numbers:
5961
[!code-html[Main](tutorials/build-your-first-blazor-app/sample/Pages/Index.cshtml?range=1-10,20,30,40-50]
6062
```
6163

62-
For C# snippets, you can reference a [C# region](https://docs.microsoft.com/dotnet/csharp/language-reference/preprocessor-directives/preprocessor-region). Whenever possible, use regions rather than line numbers, because line numbers in a code file tend to change and get out of sync with line number references in Markdown. C# regions can be nested, and if you reference the outer region, the inner `#region` and `#endregion` directives are not rendered in a snippet.
64+
For C# snippets, you can reference a [C# region](https://docs.microsoft.com/dotnet/csharp/language-reference/preprocessor-directives/preprocessor-region). Whenever possible, use regions rather than line numbers because line numbers in a code file tend to change and become out of sync with line number references in markdown. C# regions can be nested; and if you reference the outer region, the inner `#region` and `#endregion` directives aren't rendered in a snippet.
6365

6466
To render a C# region named "snippet_Example":
6567

@@ -78,27 +80,32 @@ To highlight selected lines in a rendered snippet (usually renders as yellow bac
7880

7981
## Test your changes with DocFX
8082

81-
Test your changes with the [DocFX command-line tool](https://dotnet.github.io/docfx/tutorial/docfx_getting_started.html#2-use-docfx-as-a-command-line-tool), which creates a locally hosted version of the site. DocFX doesn't render style and site extensions created for docs.microsoft.com.
83+
Test your changes with the [DocFX command-line tool](https://dotnet.github.io/docfx/tutorial/docfx_getting_started.html#2-use-docfx-as-a-command-line-tool), which creates a locally-hosted version of the site. DocFX doesn't render style and site extensions created for docs.microsoft.com.
8284

83-
DocFX requires the .NET Framework on Windows, or Mono for Linux or macOS.
85+
DocFX requires the .NET Framework on Windows or Mono for Linux/macOS.
8486

8587
### Windows instructions
8688

8789
* Download and unzip *docfx.zip* from [DocFX releases](https://github.com/dotnet/docfx/releases).
8890
* Add DocFX to your PATH.
89-
* In a command-line window, navigate to root of the repo (where the *docfx.json* file resides) and run the following command:
91+
* In a console window, navigate to root of the repo (where the *docfx.json* file resides) and run the following command:
9092

91-
```
92-
docfx --serve
93-
```
93+
```
94+
docfx --serve
95+
```
9496

9597
* In a browser, navigate to `http://localhost:8080`.
9698

9799
### Mono instructions
98100

99-
* Install Mono via Homebrew - `brew install mono`.
101+
* Install Mono via Homebrew:
102+
103+
```
104+
brew install mono
105+
```
106+
100107
* Download the [latest version of DocFX](https://github.com/dotnet/docfx/releases).
101-
* Extract to `\bin\docfx`.
108+
* Extract the archive to */bin/docfx*.
102109
* Create an alias for **docfx**:
103110

104111
```
@@ -111,11 +118,11 @@ DocFX requires the .NET Framework on Windows, or Mono for Linux or macOS.
111118
}
112119
```
113120

114-
* Run **docfx** from the root of the repo to build the site, and **docfx-serve** to view the site at `http://localhost:8080`.
121+
* Run `docfx` from the root of the repo to build the site, and `docfx-serve` to view the site at `http://localhost:8080`.
115122

116123
## Voice and tone
117124

118-
Our goal is to write documentation that is easily understandable by the widest possible audience. To that end we have established guidelines for writing style that we ask our contributors to follow. For more information, see [Voice and tone guidelines](https://github.com/dotnet/docs/blob/master/styleguide/voice-tone.md) in the .NET repo.
125+
Our goal is to write documentation that is easily understandable by the widest possible audience. To that end, we've established guidelines for writing style that we ask our contributors to follow. For more information, see [Voice and tone guidelines](https://github.com/dotnet/docs/blob/master/styleguide/voice-tone.md) in the .NET repo.
119126

120127
## Microsoft Writing Style Guide
121128

0 commit comments

Comments
 (0)