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/azure-resource-manager/bicep/quickstart-create-bicep-use-visual-studio.md
+11-11Lines changed: 11 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,29 +9,29 @@ ms.custom: devx-track-bicep
9
9
10
10
# Quickstart: Create Bicep files with Visual Studio
11
11
12
-
This quickstart guides you through the steps to create a [Bicep file](overview.md) with Visual Studio. You'll create a storage account and a virtual network. You'll also learn how the Bicep extension simplifies development by providing type safety, syntax validation, and autocompletion.
12
+
This quickstart guides you through the steps to create a [Bicep file](overview.md) with Visual Studio. You create a storage account and a virtual network. You also learn how the Bicep extension simplifies development by providing type safety, syntax validation, and autocompletion.
13
13
14
-
Similar authoring experience is also supported in Visual Studio Code. See [Quickstart: Create Bicep files with Visual Studio Code](./quickstart-create-bicep-use-visual-studio-code.md).
14
+
Similar authoring experience is also supported in Visual Studio Code. See [Quickstart: Create Bicep files with Visual Studio Code](./quickstart-create-bicep-use-visual-studio-code.md).
15
15
16
16
## Prerequisites
17
17
18
18
- Azure Subscription. If you don't have an Azure subscription, [create a free account](https://azure.microsoft.com/pricing/purchase-options/azure-account?cid=msft_learn) before you begin.
19
-
- Visual Studio version 17.3.0 preview 3 or newer. See [Visual Studio Preview](https://visualstudio.microsoft.com/vs/preview/).
20
-
- Visual Studio Bicep extension. See [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.visualstudiobicep).
19
+
- Visual Studio version 17.3.0 preview 3 or newer. See [Visual Studio Preview](https://visualstudio.microsoft.com/vs/preview/).
20
+
- Visual Studio Bicep extension. See [Visual Studio Marketplace](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.visualstudiobicep).
21
21
- Bicep file deployment requires either the latest [Azure CLI](/cli/azure/) or the latest [Azure PowerShell module](/powershell/azure/new-azureps-module-az).
22
22
23
23
## Add resource snippet
24
24
25
25
Launch Visual Studio and create a new file named **main.bicep**.
26
26
27
-
Visual Studio with the Bicep extension simplifies development by providing pre-defined snippets. In this quickstart, you'll add a snippet that creates a virtual network.
27
+
Visual Studio with the Bicep extension simplifies development by providing predefined snippets. In this quickstart, you add a snippet that creates a virtual network.
28
28
29
29
In *main.bicep*, type **vnet**. Select **res-vnet** from the list, and then press **[TAB]** or **[ENTER]**.
30
30
31
31
:::image type="content" source="./media/quickstart-create-bicep-use-visual-studio/add-snippet.png" alt-text="Screenshot of adding snippet for virtual network.":::
32
32
33
33
> [!TIP]
34
-
> If you don't see those intellisense options in Visual Studio, make sure you've installed the Bicep extension as specified in [Prerequisites](#prerequisites). If you have installed the extension, give the Bicep language service some time to start after opening your Bicep file. It usually starts quickly, but you will not have intellisense options until it starts.
34
+
> If you don't see those intellisense options in Visual Studio, make sure you've installed the Bicep extension as specified in [Prerequisites](#prerequisites). If you have installed the extension, give the Bicep language service some time to start after opening your Bicep file. It usually starts quickly, but you won't have intellisense options until it starts.
35
35
36
36
Your Bicep file now contains the following code:
37
37
@@ -73,7 +73,7 @@ Notice **location** has a red curly underline. This indicates a problem. Hover y
73
73
74
74
## Add parameters
75
75
76
-
Now, we'll add two parameters for the storage account name and the location. At the top of file, add:
76
+
Now, we add two parameters for the storage account name and the location. At the top of file, add:
77
77
78
78
```bicep
79
79
param storageName
@@ -89,7 +89,7 @@ You have the following parameter:
89
89
param storageName string
90
90
```
91
91
92
-
This parameter works fine, but storage accounts have limits on the length of the name. The name must have at least 3 characters and no more than 24 characters. You can specify those requirements by adding decorators to the parameter.
92
+
This parameter works fine, but storage accounts have limits on the length of the name. The name must have at least three characters and no more than 24 characters. You can specify those requirements by adding decorators to the parameter.
93
93
94
94
Add a line above the parameter, and type **@**. You see the available decorators. Notice there are decorators for both **minLength** and **maxLength**.
Instead of using a snippet to define the storage account, we'll use intellisense to set the values. Intellisense makes this step much easier than having to manually type the values.
125
+
Instead of using a snippet to define the storage account, we use intellisense to set the values. Intellisense makes this step easier than having to manually type the values.
126
126
127
-
To define a resource, use the `resource` keyword. Below your virtual network, type **resource exampleStorage**:
127
+
To define a resource, use the `resource` keyword. Below your virtual network, type **resource exampleStorage**:
128
128
129
129
```bicep
130
130
resource exampleStorage
@@ -208,7 +208,7 @@ For more information about the Bicep syntax, see [Bicep structure](./file.md).
208
208
209
209
## Deploy the Bicep file
210
210
211
-
Bicep file deployment can't be done from Visual Studio yet. You can deploy the Bicep file by using Azure CLI or Azure PowerShell:
211
+
Bicep file deployment can't be done from Visual Studio yet. You can deploy the Bicep file by using Azure CLI or Azure PowerShell:
0 commit comments