Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
In the spirit of keeping the public API of mustache.js as small as possible for maintainence reasons, the undocumented and un-tested `.to_html()` method is removed. The functionality involved, where it can rather invoke an optional function provided with the result of `.render()`, instead of returning it as a string like `.render()` does, is something that using projects very easily can do themselfs -- it does not have to be provided by mustache.js.
- Loading branch information
f3012a2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was a breaking change for me. Can you provide some migration help, what is the new to_html?
For now, I just revert to old version.
f3012a2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Absolutely!
First of all, is it important for you to provide a function that will get the rendered output as an argument? Or would it be a viable solution to use
const renderedOutput = mustache.render()
directly instead?f3012a2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If indeed you do indeed have a requirement for a function to be provided the rendered output, that could be implemented in your project as well I assume?