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

Document addition of variable parameters to an include. #3581

Merged
merged 4 commits into from
Mar 24, 2015

Conversation

daviewales
Copy link
Contributor

This fixes issue #3577.

The documentation has been updated to demonstrate variable parameters for an include.

    {% include footer.html param="value" variable-param=page.variable %}
The documentation has been updated to demonstrate variable parameters for an include.

    {% include footer.html param="value" variable-param=page.variable %}
@alfredxing
Copy link
Member

👍 Though we might want to use bold or italic instead of all caps?


{% highlight ruby %}
{% raw %}{% include footer.html param="value" %}{% endraw %}
{% raw %}{% include footer.html param="value" variable-param=page.variable %}{% endraw %}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is totally possible that I'm wrong, but I think dashes are not allowed in Liquid variables...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Dashes seem to be working on my end.

@daviewales
Copy link
Contributor Author

@alfredxing I've changed it from ALL CAPS to strong.

@@ -286,10 +286,10 @@ root of your source directory. This will embed the contents of
</p>
</div>

You can also pass parameters to an include:
You can also pass parameters to an include. Note that the variable parameter is **not** surrounded with the usual Liquid curly brackets:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand "variable parameter" in this case. What do you think about:

Omit the quotation marks if you would like to send a variable's value, and do not include the curly brackets.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That seems OK. I would probably say:

Omit the quotation marks if you would like to send a variable's value. Liquid curly brackets should not be used here.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've changed it to say

Omit the quotation marks to send a variable's value. Liquid curly brackets should not be used here:

parkr added a commit that referenced this pull request Mar 24, 2015
@parkr parkr merged commit 3a85aa0 into jekyll:master Mar 24, 2015
parkr added a commit that referenced this pull request Mar 24, 2015
@jekyll jekyll locked and limited conversation to collaborators Feb 27, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants