update tests

pull/4419/head
Conduitry 6 years ago
parent fb75588163
commit ecfae03abe

@ -124,6 +124,7 @@ function create_fragment(ctx) {
p: function update(ctx, [dirty]) {
if (dirty & /*things*/ 1) {
each_value = /*things*/ ctx[0];
validate_each_argument(each_value);
let i;
for (i = 0; i < each_value.length; i += 1) {

@ -118,6 +118,7 @@ function create_fragment(ctx) {
p: function update(ctx, [dirty]) {
if (dirty & /*things*/ 1) {
each_value = /*things*/ ctx[0];
validate_each_argument(each_value);
let i;
for (i = 0; i < each_value.length; i += 1) {

@ -93,6 +93,7 @@ function create_fragment(ctx) {
p: function update(ctx, [dirty]) {
if (dirty & /*things*/ 0) {
each_value = things;
validate_each_argument(each_value);
let i;
for (i = 0; i < each_value.length; i += 1) {

@ -2,5 +2,5 @@ export default {
compileOptions: {
dev: true
},
error: `Svelte does not allow Sets or Maps in an {#each} block. Use [...arg.values()] or [...arg.entries()] instead.`
error: `{#each} only iterates over array-like objects. You can use a spread to convert this iterable into an array.`
};

@ -1,5 +1,5 @@
<script>
const foo = new Set([1,2,3])
const foo = new Set([1, 2, 3]);
</script>
{#each foo as item}

@ -2,5 +2,5 @@ export default {
compileOptions: {
dev: true
},
error: `Svelte needs an array-like value for the {#each} block. You can spread your iterable into an array instead, e.g. [...iterable]`
error: `{#each} only iterates over array-like objects.`
};

@ -1,7 +1,3 @@
<script>
const foo = new Set([1,2,3])
</script>
{#each foo.values() as item}
{#each {} as item}
<div>{item}</div>
{/each}
Loading…
Cancel
Save