multiformats
Advanced tools
Comparing version 12.1.1 to 12.1.2
@@ -0,1 +1,13 @@ | ||
## [12.1.2](https://github.com/multiformats/js-multiformats/compare/v12.1.1...v12.1.2) (2023-10-03) | ||
### Bug Fixes | ||
* switch interface method decl style ([a33d24f](https://github.com/multiformats/js-multiformats/commit/a33d24f3ca56e4b40c80a3237e419cda261aa3e6)) | ||
### Dependencies | ||
* **dev:** bump aegir from 40.0.13 to 41.0.0 ([41f008b](https://github.com/multiformats/js-multiformats/commit/41f008b09378085adef4aede1dd504a4eba5fa80)) | ||
## [12.1.1](https://github.com/multiformats/js-multiformats/compare/v12.1.0...v12.1.1) (2023-09-05) | ||
@@ -2,0 +14,0 @@ |
@@ -11,3 +11,3 @@ /** | ||
*/ | ||
baseEncode: (bytes: Uint8Array) => string; | ||
baseEncode(bytes: Uint8Array): string; | ||
} | ||
@@ -24,3 +24,3 @@ /** | ||
*/ | ||
baseDecode: (text: string) => Uint8Array; | ||
baseDecode(text: string): Uint8Array; | ||
} | ||
@@ -58,3 +58,3 @@ /** | ||
*/ | ||
encode: (bytes: Uint8Array) => Multibase<Prefix>; | ||
encode(bytes: Uint8Array): Multibase<Prefix>; | ||
} | ||
@@ -74,3 +74,3 @@ /** | ||
*/ | ||
decode: (multibase: Multibase<Prefix>) => Uint8Array; | ||
decode(multibase: Multibase<Prefix>): Uint8Array; | ||
} | ||
@@ -77,0 +77,0 @@ /** |
@@ -53,7 +53,7 @@ import type { CID } from '../cid.js'; | ||
value: T; | ||
links: () => Iterable<[string, CID]>; | ||
tree: () => Iterable<string>; | ||
get: (path: string) => BlockCursorView<unknown>; | ||
links(): Iterable<[string, CID]>; | ||
tree(): Iterable<string>; | ||
get(path: string): BlockCursorView<unknown>; | ||
} | ||
export {}; | ||
//# sourceMappingURL=interface.d.ts.map |
@@ -8,3 +8,3 @@ import type { ByteView } from '../block/interface.js'; | ||
code: Code; | ||
encode: (data: T) => ByteView<T>; | ||
encode(data: T): ByteView<T>; | ||
} | ||
@@ -16,3 +16,3 @@ /** | ||
code: Code; | ||
decode: (bytes: ByteView<T>) => T; | ||
decode(bytes: ByteView<T>): T; | ||
} | ||
@@ -19,0 +19,0 @@ /** |
@@ -36,3 +36,3 @@ /** | ||
*/ | ||
digest: (input: Uint8Array) => Promise<MultihashDigest<Code>> | MultihashDigest<Code>; | ||
digest(input: Uint8Array): Promise<MultihashDigest<Code>> | MultihashDigest<Code>; | ||
/** | ||
@@ -58,4 +58,4 @@ * Name of the multihash | ||
export interface SyncMultihashHasher<Code extends number = number> extends MultihashHasher<Code> { | ||
digest: (input: Uint8Array) => MultihashDigest<Code>; | ||
digest(input: Uint8Array): MultihashDigest<Code>; | ||
} | ||
//# sourceMappingURL=interface.d.ts.map |
@@ -23,6 +23,6 @@ import type { MultibaseEncoder, MultibaseDecoder, Multibase } from '../bases/interface.js'; | ||
readonly bytes: ByteView<Link<Data, Format, Alg, V>>; | ||
equals: (other: unknown) => other is Link<Data, Format, Alg, Version>; | ||
toString: <Prefix extends string>(base?: MultibaseEncoder<Prefix>) => ToString<Link<Data, Format, Alg, Version>, Prefix>; | ||
link: () => Link<Data, Format, Alg, V>; | ||
toV1: () => Link<Data, Format, Alg, 1>; | ||
equals(other: unknown): other is Link<Data, Format, Alg, Version>; | ||
toString<Prefix extends string>(base?: MultibaseEncoder<Prefix>): ToString<Link<Data, Format, Alg, Version>, Prefix>; | ||
link(): Link<Data, Format, Alg, V>; | ||
toV1(): Link<Data, Format, Alg, 1>; | ||
} | ||
@@ -29,0 +29,0 @@ export interface LinkJSON<T extends UnknownLink = UnknownLink> { |
{ | ||
"name": "multiformats", | ||
"version": "12.1.1", | ||
"version": "12.1.2", | ||
"description": "Interface for multihash, multicodec, multibase and CID", | ||
@@ -294,3 +294,3 @@ "author": "Mikeal Rogers <mikeal.rogers@gmail.com> (https://www.mikealrogers.com/)", | ||
"@types/node": "^20.3.1", | ||
"aegir": "^40.0.11", | ||
"aegir": "^41.0.0", | ||
"buffer": "^6.0.3", | ||
@@ -297,0 +297,0 @@ "cids": "^1.1.9", |
@@ -14,3 +14,3 @@ // Base encoders / decoders just base encode / decode between binary and | ||
*/ | ||
baseEncode: (bytes: Uint8Array) => string | ||
baseEncode(bytes: Uint8Array): string | ||
} | ||
@@ -28,3 +28,3 @@ | ||
*/ | ||
baseDecode: (text: string) => Uint8Array | ||
baseDecode(text: string): Uint8Array | ||
} | ||
@@ -65,3 +65,3 @@ | ||
*/ | ||
encode: (bytes: Uint8Array) => Multibase<Prefix> | ||
encode(bytes: Uint8Array): Multibase<Prefix> | ||
} | ||
@@ -82,3 +82,3 @@ | ||
*/ | ||
decode: (multibase: Multibase<Prefix>) => Uint8Array | ||
decode(multibase: Multibase<Prefix>): Uint8Array | ||
} | ||
@@ -85,0 +85,0 @@ |
@@ -71,5 +71,5 @@ /* eslint-disable @typescript-eslint/no-unnecessary-type-constraint */ | ||
links: () => Iterable<[string, CID]> | ||
tree: () => Iterable<string> | ||
get: (path: string) => BlockCursorView<unknown> | ||
links(): Iterable<[string, CID]> | ||
tree(): Iterable<string> | ||
get(path: string): BlockCursorView<unknown> | ||
} |
@@ -9,3 +9,3 @@ import type { ByteView } from '../block/interface.js' | ||
code: Code | ||
encode: (data: T) => ByteView<T> | ||
encode(data: T): ByteView<T> | ||
} | ||
@@ -18,3 +18,3 @@ | ||
code: Code | ||
decode: (bytes: ByteView<T>) => T | ||
decode(bytes: ByteView<T>): T | ||
} | ||
@@ -21,0 +21,0 @@ |
@@ -47,3 +47,3 @@ // # Multihash | ||
*/ | ||
digest: (input: Uint8Array) => Promise<MultihashDigest<Code>> | MultihashDigest<Code> | ||
digest(input: Uint8Array): Promise<MultihashDigest<Code>> | MultihashDigest<Code> | ||
@@ -72,3 +72,3 @@ /** | ||
export interface SyncMultihashHasher<Code extends number = number> extends MultihashHasher<Code> { | ||
digest: (input: Uint8Array) => MultihashDigest<Code> | ||
digest(input: Uint8Array): MultihashDigest<Code> | ||
} |
@@ -36,8 +36,8 @@ /* eslint-disable @typescript-eslint/no-unnecessary-type-constraint */ | ||
equals: (other: unknown) => other is Link<Data, Format, Alg, Version> | ||
equals(other: unknown): other is Link<Data, Format, Alg, Version> | ||
toString: <Prefix extends string>(base?: MultibaseEncoder<Prefix>) => ToString<Link<Data, Format, Alg, Version>, Prefix> | ||
link: () => Link<Data, Format, Alg, V> | ||
toString<Prefix extends string>(base?: MultibaseEncoder<Prefix>): ToString<Link<Data, Format, Alg, Version>, Prefix> | ||
link(): Link<Data, Format, Alg, V> | ||
toV1: () => Link<Data, Format, Alg, 1> | ||
toV1(): Link<Data, Format, Alg, 1> | ||
} | ||
@@ -44,0 +44,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
276425