End notes at the end of the document - sorted by chapters?

Hi,
i would like to have end notes at the end of the document - sorted by chapters. For books this is a quite common method.
LibreOffice doesn’t seem to have that function. Or do you know how to get round that limitation?!

See Is it possible to number endnotes by chapter?

Hm, it is not possible in Libreoffice as it seems. I hope there is a feature request somewhere for that…

See how @Curbuntu solved it in his question. My first comment is an improvement on his hack.

@pierre-yves samin proposes an alternative strategy in another answer to the same question: group all notes related to a chapter at the end of the chapter instead of bottom of page or end of document.

If the link answers your question, please tick the check mark at left and close the question for community benefit.