New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adding template, suggessted fix for @Earl-Brown #990
Conversation
Adding |
@@ -72,7 +72,8 @@ exports = module.exports = function directory(root, options){ | |||
, icons = options.icons | |||
, view = options.view || 'tiles' | |||
, filter = options.filter | |||
, root = normalize(root + sep); | |||
, root = normalize(root + sep) | |||
, template = options.template || __dirname + '/../public/directory.html';; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is an extraneous semi-colon on this line.
my bad .. haste with copy/paste since at first was just suggesting. working on the test now. |
@dougwilson I hope I did that right |
A test you added doesn't pass. You can see the output at https://travis-ci.org/senchalabs/connect/jobs/16282820 |
@@ -118,6 +117,26 @@ describe('directory()', function(){ | |||
}); | |||
}); | |||
|
|||
describe('when setting a custom template', function () { | |||
var app = connect(connect.directory('test/fixtures'),{template: __dirname + '/shared/template.html'}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The second closing parenthesis is in the wrong location.
@dougwilson good to go |
Great. I'll merge it in in a bit. |
@dougwilson just wondering when you might get a chance to merge this? i especially would love to have this for the project i'm working on. i appreciate it. |
Soon. I have to add documentation on how to actually use the |
@@ -72,7 +72,8 @@ exports = module.exports = function directory(root, options){ | |||
, icons = options.icons | |||
, view = options.view || 'tiles' | |||
, filter = options.filter | |||
, root = normalize(root + sep); | |||
, root = normalize(root + sep) | |||
, template = options.template || __dirname + '/../public/directory.html'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this going to work in windows? one of these windows people are going to complain eventually...
No description provided.