<script>
const obj = {
key: "foo"
};
</script>
{#each obj as i, { key }}
{key}
{/each}
I learned the hard way that the i should come after the { key }, not before it, i.e.
{#each obj as { key }, i}
{key}
{/each}
The plugin did not report anything wrong, which resulted in Prettier failing and I wasn't sure why. Took me a while to figure that one out
Plugin version: 0.21.2
In my code I had something like:
I learned the hard way that the
i
should come after the{ key }
, not before it, i.e.The plugin did not report anything wrong, which resulted in Prettier failing and I wasn't sure why. Took me a while to figure that one out Plugin version: 0.21.2