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: articles/storage/blobs/storage-blob-upload-javascript.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,11 +29,11 @@ Use the following table to find the correct upload method based on the blob clie
29
29
|Client|Upload method|
30
30
|--|--|
31
31
|[BlobClient](/javascript/api/@azure/storage-blob/blobclient)|The SDK would needs to know the blob type you want to upload to. Because this is the base class for the other Blob clients, it does not have upload methods. It is mostly useful for operations that are common to the child blob classes. For uploading, create specific blob clients directly or get specific blob clients from ContainerClient.|
32
-
|[BlockBlobClient](/javascript/api/@azure/storage-blob/blockblobclient)|* upload()<br>* stageBlock() and commitBlockList()|
32
+
|[BlockBlobClient](/javascript/api/@azure/storage-blob/blockblobclient)|This is the **most common upload client**:<br>* upload()<br>* stageBlock() and commitBlockList()|
## <aname="upload-by-using-a-file-path"></a>Upload with BlockBlobClient by using a file path
37
37
38
38
The following example uploads a local file to blob storage with the [BlockBlobClient](/javascript/api/@azure/storage-blob/blockblobclient) object. The [options](/javascript/api/@azure/storage-blob/blockblobparalleluploadoptions) object allows you to pass in your own metadata and [tags](storage-manage-find-blobs.md#blob-index-tags-and-data-management), used for indexing, at upload time:
39
39
@@ -53,7 +53,7 @@ async function createBlobFromLocalPath(containerClient, blobName, localFileWithP
53
53
}
54
54
```
55
55
56
-
## Upload by using a Stream
56
+
## <aname="upload-by-using-a-stream"></a>Upload with BlockBlobClient by using a Stream
57
57
58
58
The following example uploads a readable stream to blob storage with the [BlockBlobClient](/javascript/api/@azure/storage-blob/blockblobclient) object. Pass in the BlockBlobUploadStream [options](/javascript/api/@azure/storage-blob/blockblobuploadstreamoptions) to affect the upload:
59
59
@@ -104,7 +104,7 @@ const myTransform = new Transform({
104
104
105
105
```
106
106
107
-
## Upload by using a BinaryData object
107
+
## <aname="upload-by-using-a-binarydata-object"></a>Upload with BlockBlobClient by using a BinaryData object
108
108
109
109
The following example uploads a Node.js buffer to blob storage with the [BlockBlobClient](/javascript/api/@azure/storage-blob/blockblobclient) object. Pass in the BlockBlobParallelUpload [options](/javascript/api/@azure/storage-blob/blockblobparalleluploadoptions) to affect the upload:
110
110
@@ -130,7 +130,7 @@ async function createBlobFromBuffer(containerClient, blobName, buffer, uploadOpt
130
130
}
131
131
```
132
132
133
-
## Upload a string
133
+
## <aname="upload-a-string"></a>Upload a string with BlockBlobClient
134
134
135
135
The following example uploads a string to blob storage with the [BlockBlobClient](/javascript/api/@azure/storage-blob/blockblobclient) object. Pass in the BlockBlobUploadOptions [options](/javascript/api/@azure/storage-blob/blockblobuploadoptions) to affect the upload:
0 commit comments