Skip to content

Commit 744e2e5

Browse files
committed
Cover the vscode extract feature
1 parent bfb9943 commit 744e2e5

5 files changed

+23
-3
lines changed
Loading
Loading
Loading
Loading

articles/azure-resource-manager/bicep/visual-studio-code.md

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Create Bicep files by using Visual Studio Code
33
description: Learn how to use Visual Studio Code to create Bicep files.
44
ms.topic: how-to
55
ms.custom: devx-track-bicep
6-
ms.date: 11/21/2024
6+
ms.date: 12/10/2024
77
---
88

99
# Create Bicep files by using Visual Studio Code
@@ -205,17 +205,37 @@ The yellow light bulb in VS Code represents a quick fix suggestion. It appears w
205205

206206
:::image type="content" source="./media/visual-studio-code/visual-studio-code-bicep-context-quick-fix-suggestions.png" alt-text="Screenshot of Visual Studio Code quick fix suggestions.":::
207207

208-
For the extract commands, see [Extract paramters, variables, and types](#extract-parameters-variables-and-types). In **More Actions**, it suggests adding [decorators](./variables.md#use-decorators).
208+
For the extract commands, see [Extract parameters, variables, and types](#extract-parameters-variables-and-types). In **More Actions**, it suggests adding [decorators](./variables.md#use-decorators).
209209

210210
## Extract parameters, variables, and types
211211

212212
Extracting [variables](./variables.md), [parameters](./parameters.md), and [user-defined data types](./user-defined-data-types.md) involves isolating and defining these components from existing code to improve code structure, maintainability, and clarity.
213213

214-
The following screenshot shows a definition of a storage account resource. You can extract a parameter or a variable, or a user-defined data type based of a property, such as `kind`. Select the `kind` line from the code, and then select the yellow light bulb icon, the context windows shows the available extract options.
214+
The following screenshot shows a definition of a storage account resource. You can extract a parameter or a variable, or a user-defined data type based of a property, such as `kind`.
215+
216+
Select the `kind` line from the code, and then select the yellow light bulb icon. The context windows shows the available extract options.
215217

216218
:::image type="content" source="./media/visual-studio-code/visual-studio-code-azure-variable-parameter-type-extraction.png" alt-text="Screenshot of variable, parameter, type extraction.":::
217219

220+
- **Extract variable**: creates a new variable, and give you an option to update the variable name:
221+
222+
:::image type="content" source="./media/visual-studio-code/visual-studio-code-azure-variable-parameter-type-extract-variable.png" alt-text="Screenshot of extracting variable.":::
223+
224+
- **Extract parameter of type \<data-type>**: create a new parameter, and give you an option to update the parameter name:
225+
226+
:::image type="content" source="./media/visual-studio-code/visual-studio-code-azure-variable-parameter-type-extract-parameter.png" alt-text="Screenshot of extracting parameter.":::
227+
228+
- **Extract parameter of type \<data-type>** with allowed values: create a new parameter, and give you an option to update the parameter name:
229+
230+
:::image type="content" source="./media/visual-studio-code/visual-studio-code-azure-variable-parameter-type-extract-parameter-with-allowed-values.png" alt-text="Screenshot of extracting parameter with allowed values.":::
231+
232+
After the extract, it requires some modification.
233+
234+
- **Extract user-defined type**:
235+
236+
:::image type="content" source="./media/visual-studio-code/visual-studio-code-azure-variable-parameter-type-extract-parameter-with-allowed-values.png" alt-text="Screenshot of extracting parameter with allowed values.":::
218237

238+
After the extract, it requires some modification.
219239

220240
## View documentation
221241

0 commit comments

Comments
 (0)