From 4b9b0c6fba1023a7efedb60f00ec93a6643c091e Mon Sep 17 00:00:00 2001 From: Simon H <5968653+dummdidumm@users.noreply.github.com> Date: Wed, 17 Feb 2021 09:45:32 +0100 Subject: [PATCH] (fix) embed check (#208) When checking if an embed starts after a node, return early if that node is not at the top level of html, because embeds cannot start after it. Fixes #207 --- CHANGELOG.md | 4 ++++ src/print/node-helpers.ts | 6 ++++++ test/printer/samples/comment-at-end.html | 6 ++++++ 3 files changed, 16 insertions(+) create mode 100644 test/printer/samples/comment-at-end.html diff --git a/CHANGELOG.md b/CHANGELOG.md index ef4a502e..7e8b07f8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # prettier-plugin-svelte changelog +## 2.1.6 (Unreleased) + +* Fix wrong removal of comment ([#207](https://github.com/sveltejs/prettier-plugin-svelte/issues/207)) + ## 2.1.5 * Fix retrieval of comment belonging to `