Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

invalid-animation error when a keyed each block contains a comment in addition to the sole child #6019

Closed
maxlath opened this issue Feb 23, 2021 · 3 comments

Comments

@maxlath
Copy link
Contributor

maxlath commented Feb 23, 2021

Describe the bug
When the each block contains a comment, the compiler throws an invalid-animation error

The reason seems to be that EachBlock doesn't filter-out comments when testing if this.children.length !== 1

To Reproduce
See https://svelte.dev/repl/d868b86121f64a67986c420d21e32bc8?version=3.32.3

Expected behavior
Comments should be ignored by the validation

Severity
Somewhat annoying, as realizing that the comment counts as a child might take a while.

@stale
Copy link

stale bot commented Jun 26, 2021

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale-bot label Jun 26, 2021
@stale stale bot removed the stale-bot label Jun 26, 2021
@stale stale bot removed the stale-bot label Jun 27, 2021
@maxlath
Copy link
Contributor Author

maxlath commented Jun 28, 2021

@dummdidumm
Copy link
Member

Duplicate of #3999

@dummdidumm dummdidumm marked this as a duplicate of #3999 Jul 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants