Minor copyediting, no new content added.

This commit is contained in:
Anthony Fok 2014-12-24 04:55:11 -07:00
parent e3433e6afb
commit 68cea07072
3 changed files with 18 additions and 18 deletions

View file

@ -25,7 +25,7 @@ and each section will use the corresponding type. If you are taking advantage of
this, then each new piece of content you place into a section will automatically
inherit the type.
Alternatively you can set the type in the meta data under the key "type".
Alternatively, you can set the type in the meta data under the key "`type`".
## Creating new content of a specific type
@ -53,24 +53,24 @@ whenever a specific file is not present.
*Remember, all of the following are optional:*
### Create Type Directory
Create a directory with the name of the type in layouts. Type is always singular. *Eg /layouts/post*.
Create a directory with the name of the type in `layouts`. Type is always singular. *E.g. `/layouts/post`*.
### Create single template
Create a file called single.html inside your directory. *Eg /layouts/post/single.html*.
Create a file called `single.html` inside your directory. *E.g. `/layouts/post/single.html`*.
### Create list template
Create a file called list.html inside your directory. *Eg /layouts/post/list.html*.
Create a file called `list.html` inside your directory. *E.g. `/layouts/post/list.html`*.
### Create views
Many sites support rendering content in a few different ways, for
instance a single page view and a summary view to be used when displaying a list
Many sites support rendering content in a few different ways, for instance,
a single page view and a summary view to be used when displaying a list
of contents on a single page. Hugo makes no assumptions here about how you want
to display your content, and will support as many different views of a content
type as your site requires. All that is required for these additional views is
that a template exists in each layout/type directory with the same name.
that a template exists in each layouts/`TYPE` directory with the same name.
### Create a corresponding archetype
Create a file called `type`.md in the /archetypes directory *Eg /archetypes/post.md*.
Create a file called <code><em>type</em>.md</code> in the `/archetypes` directory. *E.g. `/archetypes/post.md`*.
More details about archetypes can be found at the [archetypes docs](/content/archetypes)
More details about archetypes can be found at the [archetypes docs](/content/archetypes).

View file

@ -80,9 +80,9 @@ Now, reference the partial template from your page template:
A few alternatives exist to [Disqus](http://disqus.com):
* [Intense Debate](http://intensedebate.com/)
* [LiveFyre](http://livefyre.com/)
* [Moot](http://muut.com)
* [IntenseDebate](http://intensedebate.com/)
* [Livefyre](http://livefyre.com/)
* [Muut](http://muut.com)
* [多说](http://duoshuo.com/) ([Duoshuo](http://duoshuo.com/), popular in China)
* [Kaiju](http://github.com/spf13/kaiju)

View file

@ -23,10 +23,10 @@ different type of content to the content itself.
## Creating a content view
To create a new view simple create a template in each of your different
content type directories with the view name. In the following example we
To create a new view, simple create a template in each of your different
content type directories with the view name. In the following example, we
have created a "li" view and a "summary" view for our two content types
of post and project. As you can see these sit next to the [single
of post and project. As you can see, these sit next to the [single
content view](/templates/content) template "single.html". You can even
provide a specific view for a given type and continue to use the
\_default/single.html for the primary view.
@ -86,10 +86,10 @@ templates](/templates/list)).
</div>
</section>
In the above example you will notice that we have called .Render and passed in
which view to render the content with. Render is a special function available on
In the above example, you will notice that we have called `.Render` and passed in
which view to render the content with. `.Render` is a special function available on
a content which tells the content to render itself with the provided view template.
In this example we are not using the li view. To use this we would
In this example, we are not using the li view. To use this we would
change the render line to `{{ .Render "li" }}`.