I have this following layout, with jekyll 3.7.3;
declare A = apple
include file.html > declare A = orange
print A => orange
I am confused to how did A=orange leaked to the parent layout, in the jekyll's doc, says that the variables assess thru layout in the liquid tag. Does this apply to the include as well? It makes no sense in where child layout overwritten the parent layout, as it is saying in the github conversation and this conversation.
So my question is how is this inheritance work?
From what I understand about inheritance, there should be some control how the child variable be overwrite the parent variable. From the document, I believe it is through the variable layout. Then this should look like this;
declare A = apple
include file.html > declare layout.A = orange
print A => apple
Other case is;
declare A = apple
include file.html > print A => apple
declare A = orange
print A => orange
What is the point of having an argument in the include if the child include inheritances the value without explicitly tells it to.
also with the leak variables into the include child, would mean the child include is not isolated any more for the purpose of special case like it is saying here