Repository navigation
fix(html-email-formatter): drop the unmaintained pretty package - #68
Merged
Merged
Conversation
🦋 Changeset detectedLatest commit: 6690c6e The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
…wlines to a newline
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
html-email-formatternow calls js-beautify directly instead of going throughpretty. Output is unchanged.prettyhasn't had a release since 2017, and it pulls incondense-newlines,extend-shallow,is-whitespace,kind-ofandis-buffer. This package now does the small part ofprettyit used:indent_inner_html, andcode/pre/em/strong/spanleft unformatted. Options still override them.ocdpass, copied as written.pretty'sis-whitespacecounts"and U+180E as whitespace, so a line of indentation plus"still gets trimmed, and an emptynewlinesstill falls back to\n.EmailFormatterOptionsreplacesParameters<typeof pretty>[1] & HTMLBeautifyOptions. It only widens:ocdis now optional.prettyalso passedcondense-newlinesoptions such assep,minandkeepWhitespacethrough to theocdpass. The types never allowed them, and they're now ignored. Every known caller passesocd: false: hydra's editor and language worker, and parcel's process-pipeline.js-beautify stays on
~1.13.4. #37 pinned it there for parity with parcel-standalone, and 1.15 changes the output on at least one standard component's<script>.Verification
force-expand-multiline, no options, andocd: true. All 668 outputs are byte-identical to 0.0.5.requireandimport, and typechecks under nodenext and node10.newlinesfallback. Lint, Prettier and the typecheck are clean.