Closed mledwards closed 9 years ago
Absolutely! Should be pretty easy to pass the file path as the third parameter: https://github.com/alanshaw/grunt-include-replace/blob/master/tasks/includereplace.js#L115
PR would be gratefully accepted!
Hey @mledwards I had a spare 5 minutes so I added this for you - released as version 3.2.0
Thanks for the prompt response @alanshaw!
Could it reference the generated file instead of the include? I think there's more value to the generated file as you then have access to construct a URL to the page.
I'd also suggest the path is relative to the grunt file, as it's unlikely you'll need to go further back than that for web purposes?
Scrap that, I think my requirement is a little niche so I built a small plugin for it: https://github.com/mledwards/grunt-filepath
Thanks!
Hi there,
Is it possible to get the file path in the processIncludeContents function for manipulation?
I'm trying to get the dynamic URL in static HTML pages.
Thanks!