Closed EvanHahn closed 4 years ago
Thanks for the PR, and sorry I've been so late to respond to this. I'm not sure the best way of doing this, whether to use a predicate on the whole request, or a regular expression on the resource or file path, or just to have a :dot-files?
option that is more specific, but would account for most cases.
I'd vote to add this option as is and document several common use cases. I think that lets it be easy for developers (just copy it from the docs) and still be flexible.
Bumping this. Is this something we want to merge? (No rush!)
Thanks for reminding me about this. Having come back to this I'm now a little more certain what I want.
:exclude?
should be :exclude
, and it should be a function on the file or resource name.
Make sure all lines are wrapped at 80 characters, and preserve existing indentation.
Unfortunately, I don't think I have time to finish this pull request. I'm going to close this for now, but anyone can feel free to commandeer this branch and see it through.
This adds an
:exclude?
option toroute/files
androute/resources
. This option is a function that will be called with the current request, and if the function returns true, the file will be ignored.This is an updated version of #174.