Add missing file extensions to imports
This commit is contained in:
parent
632184afb8
commit
ad07d260ab
|
@ -1,8 +1,8 @@
|
|||
import { run, bench, group, baseline } from 'mitata'
|
||||
import { initNostrWasm } from 'nostr-wasm'
|
||||
import { NostrEvent } from './core'
|
||||
import { finalizeEvent, generateSecretKey } from './pure'
|
||||
import { setNostrWasm, verifyEvent } from './wasm'
|
||||
import { NostrEvent } from './core.ts'
|
||||
import { finalizeEvent, generateSecretKey } from './pure.ts'
|
||||
import { setNostrWasm, verifyEvent } from './wasm.ts'
|
||||
import { AbstractRelay } from './abstract-relay.ts'
|
||||
import { Relay as PureRelay } from './relay.ts'
|
||||
import { alwaysTrue } from './helpers.ts'
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { describe, test, expect } from 'bun:test'
|
||||
import fetch from 'node-fetch'
|
||||
import { useFetchImplementation, fetchRelayInformation } from './nip11'
|
||||
import { useFetchImplementation, fetchRelayInformation } from './nip11.ts'
|
||||
|
||||
// TODO: replace with a mock
|
||||
describe('requesting relay as for NIP11', () => {
|
||||
|
|
14
nip29.ts
14
nip29.ts
|
@ -1,10 +1,10 @@
|
|||
import { AbstractSimplePool } from './abstract-pool'
|
||||
import { Subscription } from './abstract-relay'
|
||||
import { decode } from './nip19'
|
||||
import type { Event } from './core'
|
||||
import { fetchRelayInformation } from './nip11'
|
||||
import { normalizeURL } from './utils'
|
||||
import { AddressPointer } from './nip19'
|
||||
import { AbstractSimplePool } from './abstract-pool.ts'
|
||||
import { Subscription } from './abstract-relay.ts'
|
||||
import { decode } from './nip19.ts'
|
||||
import type { Event } from './core.ts'
|
||||
import { fetchRelayInformation } from './nip11.ts'
|
||||
import { normalizeURL } from './utils.ts'
|
||||
import { AddressPointer } from './nip19.ts'
|
||||
|
||||
export function subscribeRelayGroups(
|
||||
pool: AbstractSimplePool,
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { describe, test, expect } from 'bun:test'
|
||||
import { hexToBytes } from '@noble/hashes/utils'
|
||||
import { makeNwcRequestEvent, parseConnectionString } from './nip47'
|
||||
import { makeNwcRequestEvent, parseConnectionString } from './nip47.ts'
|
||||
import { decrypt } from './nip04.ts'
|
||||
import { NWCWalletRequest } from './kinds.ts'
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
import { test, expect } from 'bun:test'
|
||||
import { decrypt, encrypt } from './nip49'
|
||||
import { decrypt, encrypt } from './nip49.ts'
|
||||
import { hexToBytes } from '@noble/hashes/utils'
|
||||
|
||||
test('encrypt and decrypt', () => {
|
||||
|
|
2
nip49.ts
2
nip49.ts
|
@ -1,7 +1,7 @@
|
|||
import { scrypt } from '@noble/hashes/scrypt'
|
||||
import { xchacha20poly1305 } from '@noble/ciphers/chacha'
|
||||
import { concatBytes, randomBytes } from '@noble/hashes/utils'
|
||||
import { Bech32MaxSize, encodeBytes } from './nip19'
|
||||
import { Bech32MaxSize, encodeBytes } from './nip19.ts'
|
||||
import { bech32 } from '@scure/base'
|
||||
|
||||
export function encrypt(sec: Uint8Array, password: string, logn: number = 16, ksb: 0x00 | 0x01 | 0x02 = 0x02): string {
|
||||
|
|
4
nip58.ts
4
nip58.ts
|
@ -1,9 +1,9 @@
|
|||
import { Event, EventTemplate } from './core'
|
||||
import { Event, EventTemplate } from './core.ts'
|
||||
import {
|
||||
BadgeAward as BadgeAwardKind,
|
||||
BadgeDefinition as BadgeDefinitionKind,
|
||||
ProfileBadges as ProfileBadgesKind,
|
||||
} from './kinds'
|
||||
} from './kinds.ts'
|
||||
|
||||
/**
|
||||
* Represents the structure for defining a badge within the Nostr network.
|
||||
|
|
4
nip75.ts
4
nip75.ts
|
@ -1,5 +1,5 @@
|
|||
import { Event, EventTemplate } from './core'
|
||||
import { ZapGoal } from './kinds'
|
||||
import { Event, EventTemplate } from './core.ts'
|
||||
import { ZapGoal } from './kinds.ts'
|
||||
|
||||
/**
|
||||
* Represents a fundraising goal in the Nostr network as defined by NIP-75.
|
||||
|
|
2
nip94.ts
2
nip94.ts
|
@ -1,4 +1,4 @@
|
|||
import { Event, EventTemplate } from './core'
|
||||
import { Event, EventTemplate } from './core.ts'
|
||||
import { FileMetadata as FileMetadataKind } from './kinds.ts'
|
||||
|
||||
/**
|
||||
|
|
4
nip96.ts
4
nip96.ts
|
@ -1,6 +1,6 @@
|
|||
import { sha256 } from '@noble/hashes/sha256'
|
||||
import { EventTemplate } from './core'
|
||||
import { FileServerPreference } from './kinds'
|
||||
import { EventTemplate } from './core.ts'
|
||||
import { FileServerPreference } from './kinds.ts'
|
||||
import { bytesToHex } from '@noble/hashes/utils'
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
import { describe, expect, test } from 'bun:test'
|
||||
|
||||
import { Event } from './core'
|
||||
import { ClassifiedListing, DraftClassifiedListing } from './kinds'
|
||||
import { ClassifiedListingObject, generateEventTemplate, parseEvent, validateEvent } from './nip99'
|
||||
import { finalizeEvent, generateSecretKey } from './pure'
|
||||
import { Event } from './core.ts'
|
||||
import { ClassifiedListing, DraftClassifiedListing } from './kinds.ts'
|
||||
import { ClassifiedListingObject, generateEventTemplate, parseEvent, validateEvent } from './nip99.ts'
|
||||
import { finalizeEvent, generateSecretKey } from './pure.ts'
|
||||
|
||||
describe('validateEvent', () => {
|
||||
test('should return true for a valid classified listing event', () => {
|
||||
|
|
2
wasm.ts
2
wasm.ts
|
@ -1,6 +1,6 @@
|
|||
import { bytesToHex } from '@noble/hashes/utils'
|
||||
import { Nostr as NostrWasm } from 'nostr-wasm'
|
||||
import { EventTemplate, Event, Nostr, VerifiedEvent, verifiedSymbol } from './core'
|
||||
import { EventTemplate, Event, Nostr, VerifiedEvent, verifiedSymbol } from './core.ts'
|
||||
|
||||
let nw: NostrWasm
|
||||
|
||||
|
|
Loading…
Reference in New Issue