Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(bridge-ui-v2): fixing vercel build #14052

Merged
merged 3 commits into from
Jun 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/bridge-ui-v2/src/libs/wagmi/watcher.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { watchAccount, watchNetwork, watchPublicClient, watchWalletClient } from '@wagmi/core';
import { watchAccount, watchNetwork /*, watchPublicClient, watchWalletClient*/ } from '@wagmi/core';

import { getLogger } from '$libs/util/logger';

const log = getLogger('wagmi/watcher');
const log = getLogger('wagmi:watcher');

let isWatching = false;
let unWatchNetwork: () => void;
Expand Down
6 changes: 6 additions & 0 deletions packages/bridge-ui-v2/src/routes/+layout.svelte
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
<script lang="ts">
import '../app.css';

import { onDestroy, onMount } from 'svelte';

import Header from '$components/Header';
import SideNavigation from '$components/SideNavigation';
import { startWatching, stopWatching } from '$libs/wagmi';

onMount(startWatching);
onDestroy(stopWatching);
</script>

<SideNavigation>
Expand Down
9 changes: 0 additions & 9 deletions packages/bridge-ui-v2/src/routes/+layout.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,4 @@
/**
* Entry point
*/

import { startWatching } from '$libs/wagmi';

// When setting this to false your entire app will only be rendered on the client,
// which essentially means you turn your app into an SPA.
// See https://kit.svelte.dev/docs/page-options#ssr
export const ssr = false;

// Start watching for network and account changes
startWatching();
3 changes: 3 additions & 0 deletions packages/bridge-ui-v2/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ import tsconfigPaths from 'vite-tsconfig-paths';
import { defineConfig } from 'vitest/config';

export default defineConfig({
build: {
sourcemap: true,
},
plugins: [
sveltekit(),

Expand Down