Skip to content
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

Access data files from source folder #1969

Merged
merged 3 commits into from Jul 3, 2016
Merged

Access data files from source folder #1969

merged 3 commits into from Jul 3, 2016

Conversation

gemedet
Copy link
Contributor

@gemedet gemedet commented May 22, 2016

This allows pages in the source folder to access properties in the source/_data files.

For example, in source/index.html:

<p>Hello {{site.data.foo.name}}</p>

@Xuanwo
Copy link
Contributor

Xuanwo commented Jul 2, 2016

My be we can support two different data, one from site and the other from theme.
What do you think about that?
So I can access them like <p>Hello {{theme.data.foo.name}}</p>

@gemedet
Copy link
Contributor Author

gemedet commented Jul 2, 2016

Sure, that'd give us more flexibility. I think it would be a separate PR, since you'd want to access the data from the theme's templates as well.

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

Successfully merging this pull request may close these issues.

None yet

2 participants