@@ -52,11 +52,45 @@ Run a Playground
52
52
To run a playground, click the :guilabel:`Play Button` in VS Code's
53
53
top navigation bar.
54
54
55
+ .. _playground-connect-to-deployment:
56
+
57
+ Connect to a Deployment to Run a Playground
58
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
59
+
60
+ If |vsce| is not connected to a MongoDB deployment, you can
61
+ specify a connection string for the deployment you want to run your
62
+ playground against.
63
+
64
+ If you have a playground file open in |vscode-short| and do not have
65
+ an active connection, |vsce| displays
66
+ :guilabel:`Click here to add connection` at the top of your playground.
67
+
68
+ .. figure:: /images/vsce-playground-add-connection-btn.png
69
+ :figwidth: 700px
70
+ :alt: Button to add connection from playground
71
+
72
+ 1. Click this button to open the connection string dialog.
73
+
74
+ #. Enter the
75
+ :manual:`connection string </reference/connection-string/>` for the
76
+ deployment you want to run this playground against.
77
+
78
+ #. Press :guilabel:`Enter`.
79
+
80
+ #. Run your playground.
81
+
82
+ .. note::
83
+
84
+ When you connect to a deployment through the playground connection
85
+ dialog, that connection is added to your |vsce|
86
+ :guilabel:`Connections` list.
87
+
55
88
Run Selected Lines of a Playground
56
89
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
57
90
58
91
If you select a section of your playground, you may optionally run only
59
- the selected portion. Your selection can consist of a single line or multiple lines.
92
+ the selected portion. You may run either a single line or multiple lines
93
+ of your playground.
60
94
61
95
|vsce| shows the :guilabel:`Run Selected Lines from Playground` button
62
96
immediately below your selected section. Click this button to test and
0 commit comments