-
Notifications
You must be signed in to change notification settings - Fork 4
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
basePath #3
Comments
Hey, thanks! The Harp doesn’t generate any pages, you can see how we ended up dealing with that for tags on the Baseline boilerplate, but I think another good approach is to output everything onto one page and re-format it client side if you want using something like List.js Let me know if that’s helpful at all. |
In my use case, since I can't tell beforehand if it is going to be /blog1/ or /blog9000/, referring by the root wouldn't work. It would be really nice if the precompiling step would be able to figure out which basePath to put, depending on where the file is being put. I like the approach that you generated custom pages for each tag (e.g |
Can you give me more details about the |
It's more of
|
@diasdavid: the only way to handle a site being in an abitrary (unknown at build time) directory is to make sure all intrasite links are generated relative to the current document. @amitkeret posted a Jade helper for generating relative links sintaxi/harp#46 (comment). Using that helper whenever you're spitting out a path in a template should make the site robustly relative. Intralinks embedded in site content also need to use relative URLs. Extra care must be taken if post excerpts are included on index pages. Either:
|
Hi @kennethormandy , great work on getting this ghost like blog together with harp!
I saw that you have a note for setting up basePath automatically here, is this something that is easily done with harp?
I'm interested to know if it would be possible to pregenerate the whole collection of html files in advance and also the ones for views like by
/tags/*
/year/
and so on, without breaking paths of assets being included (which would require for each of this views to have a different relative path preprended)One option would be to always use root path, but that option doesn't work for me, as I need to have custom paths where the webpages will be hosted in, such as domain.com/blog1/
Thank you!
The text was updated successfully, but these errors were encountered: