Skip to content

Commit bc18f62

Browse files
committed
lint: run pnpm run format
1 parent d8a7049 commit bc18f62

File tree

19 files changed

+439
-391
lines changed

19 files changed

+439
-391
lines changed

packages/svelte5/src/components/Deferred.svelte

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
11
<script lang="ts">
22
import { pageState } from '../page.svelte'
33
4-
const { data, children, fallback }: {
4+
const {
5+
data,
6+
children,
7+
fallback,
8+
}: {
59
data: string | string[]
610
children?: any
711
fallback?: any
@@ -17,7 +21,7 @@
1721
$effect(() => {
1822
// Access pageState.props to make this effect reactive
1923
const props = pageState.props
20-
24+
2125
// Ensures the content isn't loaded before the deferred props are available
2226
window.queueMicrotask(() => {
2327
const newLoaded = keys.every((key) => typeof props[key] !== 'undefined')

packages/svelte5/src/components/Form.svelte

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,9 @@
7474
let isDirty = $state(false)
7575
let defaultData: FormData = new FormData()
7676
77-
const _method = $derived(isUrlMethodPair(action) ? action.method : (method.toLowerCase() as FormComponentProps['method']))
77+
const _method = $derived(
78+
isUrlMethodPair(action) ? action.method : (method.toLowerCase() as FormComponentProps['method']),
79+
)
7880
const _action = $derived(isUrlMethodPair(action) ? action.url : action)
7981
8082
function getFormData(): FormData {
@@ -223,6 +225,6 @@
223225
reset,
224226
defaults,
225227
submit,
226-
data: form
228+
data: form,
227229
})}
228230
</form>

packages/svelte5/src/components/Link.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
{
9797
a: { href: _href },
9898
button: { type: 'button' },
99-
}[asProp] || {}
99+
}[asProp] || {},
100100
)
101101
</script>
102102

packages/svelte5/src/components/Render.svelte

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,13 @@
3838

3939
<script lang="ts">
4040
import Render from './Render.svelte'
41-
42-
const { component, props = {}, children = [], key = null }: {
41+
42+
const {
43+
component,
44+
props = {},
45+
children = [],
46+
key = null,
47+
}: {
4348
component: ComponentType
4449
props?: PageProps
4550
children?: RenderProps[]

packages/svelte5/src/components/WhenVisible.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
as = 'div',
1010
always = false,
1111
children,
12-
fallback
12+
fallback,
1313
}: {
1414
data?: string | string[]
1515
params?: ReloadOptions

packages/svelte5/src/page.svelte.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export const pageState = $state<SveltePage>({
1212
component: '',
1313
props: {},
1414
url: '',
15-
version: ''
15+
version: '',
1616
} as SveltePage)
1717

1818
// Create a Svelte store for backward compatibility with $page syntax
@@ -24,14 +24,14 @@ export const setPage = (newPage: SveltePage) => {
2424
pageState.props = newPage.props
2525
pageState.url = newPage.url
2626
pageState.version = newPage.version
27-
27+
2828
// Copy any additional properties
29-
Object.keys(newPage).forEach(key => {
29+
Object.keys(newPage).forEach((key) => {
3030
if (key !== 'component' && key !== 'props' && key !== 'url' && key !== 'version') {
3131
;(pageState as any)[key] = (newPage as any)[key]
3232
}
3333
})
34-
34+
3535
// Also update the store for backward compatibility
3636
setPageStore(pageState)
3737
}

0 commit comments

Comments
 (0)