Skip to content

Commit

Permalink
docs: fix README mistakes [skip ci]
Browse files Browse the repository at this point in the history
resolves #23
  • Loading branch information
vishalbalaji committed Feb 11, 2024
1 parent 7395a46 commit 1091973
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ export const trpc = svelteQueryWrapper<Router>({ client });
const foo = trpc.greeting.createQuery('foo', { retry: false });
</script>
{#if $foo.isLoading}
{#if $foo.isPending}
Loading...
{:else if $foo.isError}
Error: {$foo.error.message}
Expand Down Expand Up @@ -129,7 +129,7 @@ const client = createTRPCProxyClient<Router>({
});

export function trpc(queryClient?: QueryClient) {
svelteQueryWrapper<Router>({
return svelteQueryWrapper<Router>({
client,
queryClient
});
Expand All @@ -148,7 +148,7 @@ Which can then be used in a component as such:
</script>
<p>
{#if $foo.isLoading}
{#if $foo.isPending}
Loading...
{:else if $foo.isError}
Error: {$foo.error.message}
Expand Down Expand Up @@ -237,7 +237,7 @@ Then, in the component:
const queries = data.queries();
</script>
{#if $foo.isLoading}
{#if $foo.isPending}
Loading...
{:else if $foo.isError}
{$foo.error}
Expand All @@ -247,7 +247,7 @@ Then, in the component:
<br />
{#each $queries as query}
{#if query.isLoading}
{#if query.isPending}
Loading...
{:else if query.isError}
{query.error.message}
Expand Down

0 comments on commit 1091973

Please sign in to comment.