Skip to content

Commit

Permalink
Update README.markdown
Browse files Browse the repository at this point in the history
  • Loading branch information
Hoseong Hwang committed Dec 19, 2011
1 parent d5f0d79 commit dc4080f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions README.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,17 @@ Update your bundle:

Place individual Dust template file in their own file with `.js.dust` extension:

<!-- app/assets/javascripts/dusts/demo.js.dust -->
```javascript
// app/assets/javascripts/dusts/demo.js.dust
Hello {name}! You have {count} new messages.
```

In your javascript files, require `dust-core` and your own template files.

<!-- app/assets/javascripts/application.js -->
```javascript
// app/assets/javascripts/application.js
require dust-core
require_tree ./dusts
```

All done. Your template files will be compiled and registered.

0 comments on commit dc4080f

Please sign in to comment.