Merge branch 'master' into fix

This commit is contained in:
tiero
2023-01-14 03:49:10 +01:00

View File

@@ -91,12 +91,12 @@ The NostrRPC class provides access to the Nostr public key via `this.self.pubkey
It's best to ask approval from the user before signing an event. To do so, you can emit an event to the UI and wait for the user to approve or reject the request.
```typescript
import { NostrRPC } from '@nostr-connect/connect';
import { NostrSigner } from '@nostr-connect/connect';
import { getPublicKey, signEvent, nip06 } from 'nostr-tools';
const sk = nip06.privateKeyFromSeedWords(myWords);
class MobileHandler extends NostrRPC {
class MobileHandler extends NostrSigner {
async get_public_key(): Promise<string> {
return getPublicKey(sk);
@@ -169,4 +169,4 @@ const { target, relay, metadata } = ConnectURI.fromURI(text);
await connectURI.approve(key);
// if rejects could be polite to notify the app of the rejection
await connectURI.reject(key);
```
```