Merge data from data files and src file#55
Merge data from data files and src file#55Huntedpix wants to merge 5 commits intoassemble:masterfrom
Conversation
Merge data from data file and src file via yaml front matter
|
Hi @Huntedpix thanks for the PR and sorry for the delayed response. I've checked this locally and there is data being "leaked" between pages due to merging. I'm not exactly sure where it's happening, but if you rebase your changes against master and run If you can track it down and update the PR with a fix, that would be great, but also know that we're working on the "refactor" branch so that |
As the documentation of lodash explain it, the first argument for the merge function is the destination object. (https://lodash.com/docs/2.4.2#merge) So the first argument was changing and it was not the behavior we excepted.
|
Hi @doowb ! Sorry for the delayed response, I was assign to a priority project. The leaked information come from a simple error. As I'm not familiar with lodash, I misread the documentation and I have assume the behavior of _.merge(). I've made some test locally and everything seems ok. |
This reverts commit 3714f037a791f651d043edb81a3881c3428b5c03.
Hi !
I needed to be able to merge datas from the data directory and the data from the src file (yml) to avoid re-writing of all the key (as it could sometimes be really long)
Example:
Data file "site":
src file (*.md):
To get data as:
As I think this might interest you, I created this pull request, feel free to merge :)