Skip to content

Commit

Permalink
Pickup options set in config
Browse files Browse the repository at this point in the history
  • Loading branch information
tlvince committed Jun 13, 2013
1 parent 4e2acac commit 9f6f808
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions plugin.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@ module.exports = (env, callback) ->
getView: ->
return (env, locals, contents, templates, callback) ->
try
stylus(@_text)
.set('filename', this.getFilename())
.set('paths', [path.dirname(@_filepath.full)])
options = env.config.stylus or {}
options.filename = this.getFilename()
options.paths = [path.dirname(@_filepath.full)]
stylus(@_text, options)
.use(nib())
.render (err, css) ->
if err
Expand Down

0 comments on commit 9f6f808

Please sign in to comment.