Skip to content

Conversation

@yukitakaGrid
Copy link

@yukitakaGrid yukitakaGrid commented Oct 26, 2024

Related to #16788

Modify Prettier to format Angular HTML without breaking the closing </a> tag onto a new line.

  • Update src/language-html/print/children.js to handle inline elements like a tags and keep them on the same line.
  • Adjust src/language-html/print/element.js to ensure inline elements are not broken onto new lines.
  • Update tests/integration/__tests__/format.js to add tests verifying the new behavior for inline elements like a tags.

For more details, open the Copilot Workspace session.

Related to prettier#16788

Modify Prettier to format Angular HTML without breaking the closing `</a>` tag onto a new line.

* Update `src/language-html/print/children.js` to handle inline elements like `a` tags and keep them on the same line.
* Adjust `src/language-html/print/element.js` to ensure inline elements are not broken onto new lines.
* Update `tests/integration/__tests__/format.js` to add tests verifying the new behavior for inline elements like `a` tags.

---

For more details, open the [Copilot Workspace session](https://copilot-workspace.githubnext.com/prettier/prettier/issues/16788?shareId=XXXX-XXXX-XXXX-XXXX).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant