Skip to content

Commit fcfd84d

Browse files
committed
linter
1 parent a6b597b commit fcfd84d

File tree

2 files changed

+28
-20
lines changed

2 files changed

+28
-20
lines changed

src/routes/(v2)/v2/component-ondestroy/+page.server.ts

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,27 +17,31 @@ const grids = [
1717
{
1818
id: 3,
1919
values: [7, 8, 9]
20-
},
21-
]
20+
}
21+
];
2222

2323
export const actions: Actions = {
2424
async default({ request }) {
25-
console.log('push')
25+
console.log('push');
2626
grids.push({
2727
id: 3,
2828
values: [7, 8, 9]
29-
})
29+
});
3030

31-
return {success: true}
31+
return { success: true };
3232
}
33-
}
33+
};
3434

3535
export const load: PageServerLoad = async () => {
36-
const grid_forms = await Promise.all(grids.map((grid) => superValidate(grid, zod(schema), {
37-
id: grid.id.toString()
38-
})))
36+
const grid_forms = await Promise.all(
37+
grids.map((grid) =>
38+
superValidate(grid, zod(schema), {
39+
id: grid.id.toString()
40+
})
41+
)
42+
);
3943

40-
console.log(grid_forms.length)
44+
console.log(grid_forms.length);
4145

42-
return { grid_forms }
46+
return { grid_forms };
4347
};

src/routes/(v2)/v2/component-ondestroy/+page.svelte

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,28 @@
22
import { page } from '$app/stores';
33
import type { PageData } from './$types';
44
import { superForm } from '$lib/index.js';
5-
import Form from './Form.svelte'
5+
import Form from './Form.svelte';
66
import { enhance } from '$app/forms';
77
88
let {
99
data
1010
}: {
1111
data: PageData;
1212
} = $props();
13-
14-
const superforms = $derived(data.grid_forms.map(grid_form => superForm(grid_form, {
15-
dataType: 'json'
16-
})))
13+
14+
const superforms = $derived(
15+
data.grid_forms.map((grid_form) =>
16+
superForm(grid_form, {
17+
dataType: 'json'
18+
})
19+
)
20+
);
1721
</script>
1822

1923
{#each superforms as form}
20-
<Form {form}/>
24+
<Form {form} />
2125
{/each}
2226

23-
<form method=post use:enhance>
24-
<button type=submit>Add</button>
25-
</form>
27+
<form method="post" use:enhance>
28+
<button type="submit">Add</button>
29+
</form>

0 commit comments

Comments
 (0)