Skip to content
This repository has been archived by the owner on Nov 27, 2018. It is now read-only.

Hands-on tutorial loads blank page #102

Open
Auk14HP opened this issue Oct 27, 2013 · 5 comments
Open

Hands-on tutorial loads blank page #102

Auk14HP opened this issue Oct 27, 2013 · 5 comments

Comments

@Auk14HP
Copy link

Auk14HP commented Oct 27, 2013

I recently got around this issue by reinstalling punch via GitBash. After running punch setup site; cd site; punch s (as directed by the tutorial), I then navigated to http://localhost:9009 in Chrome but all that was displayed was a blank page.

I cruised the issues looking for something similar and came across this, but after trying it's solution (delete npm's cache and reinstall punch) I'm still running into the same issue.

I'm using Windows 7, if that helps at all.

@Auk14HP
Copy link
Author

Auk14HP commented Oct 30, 2013

Any updates on this issue? I'd really like to start using Punch, but being unable to progress through the tutorial is really hindering me.

@laktek
Copy link
Owner

laktek commented Oct 30, 2013

@Auk14HP I'll try setting up Punch on a Windows 7 machine and see if there are any issues. Last time I checked on a Windows 8 tutorial did work fine.

@laktek
Copy link
Owner

laktek commented Oct 30, 2013

Meanwhile, you can use a cloud based dev environment like Nitrous.IO to try out Punch.

@tclaeys
Copy link

tclaeys commented Feb 5, 2014

I'm also using punch on Windows 7, 64 bit. I'm facing a similar problem as described above. Partials are not rendered.

I fixed the issue by adjusting the following file:lib/template_handler.js - line 235.

    _.each(basePath.split(Path.sep || "/"), function(current_dir_entry){

replaced by

    _.each(basePath.split("/"), function(current_dir_entry){

Path.sep returns \ on Windows 7, which will not work in this case.. As the basePath is always(?) starting with a /? At least basePath returns by default "/index". Applying this change allows to do a proper lookup of the parent folder (.) and find the default _partials.

Can you please have look and fix it accordingly?

Thanks!

@s-oram
Copy link

s-oram commented Jan 20, 2015

I've applied the fix above and sent a pull request. #118

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants