Skip to content

Commit 62d7152

Browse files
authored
DOCSP-32718: stableapi basic UE code comments (#760)
* DOCSP-32718: stableapi basic UE code comments * fixes
1 parent 89f96cf commit 62d7152

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed
Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,11 @@
1+
// Stable API - no options
2+
13
// begin serverApiVersion
24
const { MongoClient, ServerApiVersion } = require("mongodb");
35

6+
// Replace the placeholders in the connection string uri with your credentials
47
const uri = "mongodb+srv://<user>:<password>@<cluster-url>?retryWrites=true&w=majority";
5-
const client = new MongoClient(uri, { serverApi: ServerApiVersion.v1 });
6-
// end serverApiVersion
78

9+
// Create a client with options to specify Stable API Version 1
10+
const client = new MongoClient(uri, { serverApi: ServerApiVersion.v1 });
11+
// end serverApiVersion

0 commit comments

Comments
 (0)