Skip to content

Commit

Permalink
Clarify README a bit
Browse files Browse the repository at this point in the history
  • Loading branch information
Brendan Loudermilk committed Feb 21, 2015
1 parent 47a212c commit bd0a778
Showing 1 changed file with 15 additions and 15 deletions.
30 changes: 15 additions & 15 deletions README.md
Expand Up @@ -59,34 +59,34 @@ exports.config =

### Additional project-specific configuration

You can set the context and configure Handlebars in your project by using an extra file (default: `./staticHandlebarsExtras.js` in your projects root directory).
You can set the context and configure Handlebars in your project by providing an
include file.

```coffee
exports.config =
plugins:
staticHandlebars:
includeFile: 'app/another_directory'
includeFile: 'app/another_directory/include.js'
```

The file may look like this:
```coffee
/*
Parameters:
- handlebars -> reference to the handlebars object

Returns:
- context -> object which represents the context in which the templates will be executed
*/
###
Parameters:
- handlebars -> reference to the handlebars object
Returns:
- context -> object which represents the context in which the templates will
be executed
###

module.exports = function(handlebars) {
var context = {
module.exports = (handlebars) ->
context =
color: 'blue'
};

// make calls on the 'handlebars'-variable to define additional helpers etc.
# make calls on the `handlebars` variable to define additional helpers etc.

return context;
};
context
```

## TODO
Expand Down

0 comments on commit bd0a778

Please sign in to comment.