Merge pull request #1295 from sveltejs/each-block-keyed-empty

handle empty each blocks
pull/1296/head
Rich Harris 7 years ago committed by GitHub
commit 47da7d1ed6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -109,6 +109,8 @@ export default class EachBlock extends Node {
parentNode: string,
parentNodes: string
) {
if (this.children.length === 0) return;
const { generator } = this;
const each = this.var;

@ -0,0 +1,7 @@
export default {
data: {
x: [{ z: 1 }, { z: 2 }],
},
html: ``
};
Loading…
Cancel
Save