Skip to content

Commit a821e29

Browse files
committed
Proofread Fastboot-Only Use
1 parent 0413087 commit a821e29

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

README.md

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -108,13 +108,17 @@ This will result in a document along the lines of:
108108
```
109109

110110

111-
### Fastboot Only
111+
## FastBoot-Only Use
112112

113-
The primary need for this library is to support various bots and web crawlers. To that end the head content is only truly needed in a server rendered (i.e. FastBoot) environment. However, by default the library will keep the head content in sync with any transitions/data changes that occur in your Ember App while running in the browser. This can be useful for development and/or debugging.
113+
The primary need for this addon is to support various bots and web crawlers. To that end, the head content is only truly needed in a server-rendered environment like FastBoot.
114114

115-
If you do not wish to have the head content "live" while running in browser you can restrict this library to only work in FastBoot by adding the following to your `config/environment.js`:
115+
By default, the addon will keep the head content in sync with any route transitions and data changes that occur when your Ember app runs in the browser. This can be useful for development and debugging.
116+
117+
If you don't wish the head content to be "live" when the app runs in browser, you can restrict this addon to run only in FastBoot:
116118

117119
```javascript
120+
// config/environment.js
121+
118122
module.exports = function(environment) {
119123
let ENV = {
120124
'ember-cli-head': {
@@ -126,6 +130,9 @@ module.exports = function(environment) {
126130
};
127131
```
128132

133+
If you use `suppressBrowserRender`, the content of `<head>` will be the static FastBoot-rendered content throughout your app's lifecycle.
134+
135+
129136
### Upgrade to 0.4.x
130137

131138
As mentioned above you need to add the `<HeadLayout />` component once and only once in an application wide template. This template is usually `app/templates/application.hbs`, but could be different in your case. Previously, in ember-cli-head 0.3.x and below the component was appended to the document inside an instance initializer. This prevented the need for the `<HeadLayout />` component as it was automatically injected and used inside that initializer. Unfortunately, this approach needed to change so that we could render the component with the rest of the application rendering.
@@ -134,8 +141,6 @@ If you care to read more about the details of render please see the PR that intr
134141

135142
But for now, if you are upgrading to 0.4.x, you simply need to add `<HeadLayout />` component to your application wide template.
136143

137-
If you make use of this mode the content of `<head>` will be the static FastBoot rendered content through the life of your App.
138-
139144
## Contributing
140145

141146
See the [Contributing](CONTRIBUTING.md) guide for details.

0 commit comments

Comments
 (0)