Closed textbook closed 4 years ago
Hi @textbook,
thanks for your PR.
Please revert the dist
changes.
I guess this is a SemVer-minor update then as this should not break any setups. But I'm not sure as we change defaults which is an API change and so it is a breaking change because the default output changes because of this, which would require a SemVer-major release.
Updated; sorry, as the tests built the dist/
and it wasn't .gitignore
d I assume I should include it.
In terms of semver, that's a tricky one. I wouldn't necessarily consider changing a default an API change (unlike e.g. renaming or removing the configuration option). Let's think about the groups of users:
Config \ Directives | Yes | No |
---|---|---|
Explicit | No change | No change |
Default | Output changes | No change |
My guess would be that the group that has directives and is using the default configuration will be pretty small, maybe even none. Only people who were relying on this tool to strip out those directives but didn't explicitly set ignoreCustomComments
to []
or false
would see any changes to their output, and that change only alters any behaviour if, despite wanting SSI to definitely not happen, it was enabled on the server.
My vote would be for minor, on that basis, but I'd be open to hearing opinions from others.
My guess would be that the group that has directives and is using the default configuration will be pretty small, maybe even none. Only people who were relying on this tool to strip out those directives but didn't explicitly set
ignoreCustomComments
to[]
orfalse
would see any changes to their output, and that change only alters any behaviour if, despite wanting SSI to definitely not happen, it was enabled on the server.
Only if no other comments with #
are there ;-)
I thin a minor release should be fine then.
The changes were released with html-minifier-terser v5.1.0.
It seems likely that anyone including these directives wants to retain them in the output, and changing the default rather than requiring explicit configuration supports folks using e.g. Create React App.
Also I should note that the extensive test coverage and well-configured automation made this codebase an absolute pleasure to work with, so thanks for your efforts on that front!