minor fixes

This commit is contained in:
Ren Amamiya
2023-04-20 09:47:02 +07:00
parent a3ca2ef548
commit d7c7983963
9 changed files with 61 additions and 73 deletions

View File

@@ -1,31 +1,13 @@
'use client';
import { DEFAULT_RELAYS } from '@stores/constants';
import { RelayPool } from 'nostr-relaypool';
import { createContext, useMemo } from 'react';
export const RelayContext = createContext({});
/*
const relays = [
'wss://relay.damus.io',
'wss://nostr-pub.wellorder.net',
'wss://nostr.bongbong.com',
'wss://nostr.zebedee.cloud',
'wss://nostr.fmt.wiz.biz',
'wss://relay.snort.social',
'wss://offchain.pub',
'wss://relay.current.fyi',
'wss://nostr.bitcoiner.social',
'wss://relay.nostr.info',
'wss://nostr-01.dorafactory.org',
'wss://nostr.zhongwen.world',
'wss://nostro.cc',
'wss://relay.nostr.net.in',
'wss://nos.lol',
];
*/
const relays = ['wss://welcome.nostr.wine', 'wss://relay.nostr.band', 'wss://nostr.mutinywallet.com'];
const relays = DEFAULT_RELAYS;
export default function RelayProvider({ children }: { children: React.ReactNode }) {
const pool = useMemo(() => new RelayPool(relays, { useEventCache: false, logSubscriptions: false }), []);