You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/user-documentation/soc-and-feeds.md
+7-7Lines changed: 7 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -36,19 +36,19 @@ const data = soc.payload()
36
36
37
37
### Writing SOCs
38
38
39
-
When writing a SOC, first, we need to make a writer object. Because we need to sign the chunk, we need to pass in a `signer` object. The `signer` object can be either an Ethereum private key (as a hex string or `Uint8Array`) or an instance of the [`Signer`](../api/types/signer.md) interface. The `Signer` interface can be used for integration with 3rd party Ethereum wallet applications because Swarm uses the same format for signing chunks that Ethereum uses for signing transactions.
39
+
When writing a SOC, first, we need to make a writer object. Because we need to sign the chunk, we need to pass in a `signer` object. The `signer` object can be either an Ethereum private key (as a hex string or `Uint8Array`) or an instance of the [`Signer`](../api/types/Signer.md) interface. The `Signer` interface can be used for integration with 3rd party Ethereum wallet applications because Swarm uses the same format for signing chunks that Ethereum uses for signing transactions.
40
40
41
41
:::info Default `signer`
42
42
43
43
When you are instantiating `Bee` class you can pass it a default signer that will be used if you won't specify it
44
-
directly for the `makeSOCWriter`. See [`Bee` constructor](../api/classes/bee.md#constructor) for more info.
44
+
directly for the `makeSOCWriter`. See [`Bee` constructor](../api/classes/Bee.md#constructor) for more info.
45
45
46
46
:::
47
47
48
48
:::tip Ethereum Wallet signers
49
49
50
-
If you want to use your browser Ethereum Wallet like Metamask you can use utility called [`makeEthereumWalletSigner`](../api/functions/utils.makeethereumwalletsigner.md) that we ship with bee-js
51
-
which creates a [`Signer`](../api/types/signer.md) object out of given EIP-1193 compatible provider.
50
+
If you want to use your browser Ethereum Wallet like Metamask you can use utility called [`makeEthereumWalletSigner`](../api/functions/Utils.makeEthereumWalletSigner.md) that we ship with bee-js
51
+
which creates a [`Signer`](../api/types/Signer.md) object out of given EIP-1193 compatible provider.
52
52
53
53
See it used in our example [here](https://github.com/ethersphere/examples-js/tree/master/eth-wallet-signing).
Copy file name to clipboardExpand all lines: docs/user-documentation/upload-download.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -22,9 +22,9 @@ To understand better what does it mean see [Bee docs - Keep your data alive](htt
22
22
23
23
### Data
24
24
25
-
You can upload and retrieve any `string` or `Uint8Array` data with [`uploadData`](../api/classes/bee.md#uploaddata) and [`downloadData`](../api/classes/bee.md#downloaddata) functions.
25
+
You can upload and retrieve any `string` or `Uint8Array` data with [`uploadData`](../api/classes/Bee.md#uploaddata) and [`downloadData`](../api/classes/Bee.md#downloaddata) functions.
26
26
27
-
When you download data the return type is [`Data`](../api/interfaces/data.md) interface which extends `Uint8Array` with convenience functions like:
27
+
When you download data the return type is [`Data`](../api/interfaces/Data.md) interface which extends `Uint8Array` with convenience functions like:
28
28
29
29
-`text()` that converts the bytes into UTF-8 encoded string
30
30
-`hex()` that converts the bytes into **non-prefixed** hex string
@@ -61,7 +61,7 @@ console.log(retrievedFile.contentType) // prints 'application/octet-stream'
61
61
console.log(retrievedFile.data.text()) // prints 'Bee is awesome!'
62
62
```
63
63
64
-
In browsers, you can upload directly `File` type. The filename is taken from the file object itself, but can be overwritten through the second argument of the `uploadFile` function (see the [API docs](../api/classes/bee.md#uploadfile))
64
+
In browsers, you can upload directly `File` type. The filename is taken from the file object itself, but can be overwritten through the second argument of the `uploadFile` function (see the [API docs](../api/classes/Bee.md#uploadfile))
0 commit comments