Socket
Socket
Sign inDemoInstall

@microsoft/vscode-azureresources-api

Package Overview
Dependencies
0
Maintainers
10
Versions
8
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.0.3 to 2.0.4

4

CHANGELOG.md

@@ -7,2 +7,6 @@

## [2.0.4] - 2023-02-22
* Polish README
## [2.0.3] - 2023-02-01

@@ -9,0 +13,0 @@

{
"name": "@microsoft/vscode-azureresources-api",
"version": "2.0.3",
"version": "2.0.4",
"description": "Type declarations and client library for the Azure Resources extension API",
"repository": {
"type": "git",
"url": "https://github.com/Microsoft/vscode-azureresourcegroups",
"directory": "api"
},
"main": "out/src/index.js",

@@ -6,0 +11,0 @@ "types": "dist/vscode-azureresources-api.d.ts",

109

README.md

@@ -18,26 +18,13 @@ # VS Code Azure Resources API

### Resource views
### Tree views
<img align="right" src="https://github.com/microsoft/vscode-azureresourcegroups/blob/main/api/docs/media/resource-views.png?raw=true" width="50%" />
Allows multiple extensions to contribute rich features to unified resource tree views in the Azure view.
The Azure Resources extension contributes two extendable views. The Resources view, and the Workspace view. In the Resources view, clients can customize resource tree items, and have full control over resource tree item children.
Consumers of the API can:
For the Workspace view, clients can contribute root level tree items to the view. Clients have full control over these tree items and their children.
- Customize and extend the behavior of Azure resource tree items in the Azure resources tree view
- Contribute tree items to the Workspace resources tree view
- Getting your resources to show up in the Azure resources tree
- Group display name
- Adding an icon
- Contribution points
- Azure and Workspace resources
- Create Resource command
<br clear="right"/>
### Create Resource menu
### Create Resource command

@@ -57,3 +44,3 @@ <img align="right" src="https://github.com/microsoft/vscode-azureresourcegroups/blob/main/api/docs/media/create-resource.png?raw=true" width="60%" />

The VS Code API provides a `TreeDataProvider` interface for controlling tree views. The host extension splits tree views into branches, where each branch is controlled by a branch data provider. Clients can register a `BranchDataProvider` which is then responsible for providing the tree items for a branch in the tree view. `BranchDataProvider` is an extension of [VS Code's `TreeDataProvider`](https://code.visualstudio.com/api/references/vscode-api#TreeDataProvider).
The VS Code API provides a `TreeDataProvider` interface for controlling tree views. In order to make the Azure trees extensible, the host extension splits tree views into "branches", where each branch is controlled by a branch data provider. Clients can register a `BranchDataProvider` for a resource type. The registered branch data provider is then responsible for providing the tree items for that branch in the tree view. `BranchDataProvider` is an extension of [VS Code's `TreeDataProvider`](https://code.visualstudio.com/api/references/vscode-api#TreeDataProvider).

@@ -88,4 +75,2 @@ > Note: clients registering resource providers must declare that they do so in their extension manifest. See [Extension Manifest](#extension-manifest)

Clients can register branch data providers for each resource view.
### Resource provider

@@ -118,3 +103,2 @@

## Extension manifest

@@ -127,40 +111,39 @@

```ts
azure?: {
azure?: {
/**
* List of Azure resource types this extension registers a BranchDataProvider for.
*/
branches: {
/**
* List of Azure resource types this extension registers a BranchDataProvider for.
* The resource type the BranchDataProvider is registered for.
*/
branches: {
/**
* The resource type the BranchDataProvider is registered for.
*/
type: AzExtResourceType
}[];
};
type: AzExtResourceType
}[];
};
/**
* List of Workspace resource types this extension registers a BranchDataProvider for.
*/
workspace?: {
branches: {
/**
* The resource type the BranchDataProvider is registered for.
*/
type: string;
}[];
/**
* List of Workspace resource types this extension registers a BranchDataProvider for.
*/
workspace?: {
branches: {
/**
* Whether this extension registers a WorkspaceResourceProvider.
* The resource type the BranchDataProvider is registered for.
*/
resources?: boolean;
};
type: string;
}[];
/**
* Commands to add to the "Create Resource..." quick pick prompt.
* Whether this extension registers a WorkspaceResourceProvider.
*/
commands?: {
command: string;
title: string;
detail: string;
}[];
}
resources?: boolean;
};
/**
* Commands to add to the "Create Resource..." quick pick prompt.
*/
commands?: {
command: string;
title: string;
detail: string;
}[];
```

@@ -256,3 +239,3 @@

## Contribute to the Azure resources view
<!-- ## Contribute to the Azure resources view

@@ -264,3 +247,3 @@ todo

- register workspace resource provider for `type`
- register workspace resource branch data provider for `type`
- register workspace resource branch data provider for `type` -->

@@ -282,18 +265,25 @@ ## Extension dependencies

## Example extensions
The following extensions are integrated with the Azure Resources API v2. They are great examples of how to use the API.
- [Azure Dev CLI](https://github.com/Azure/azure-dev/tree/main/ext/vscode)
- [Azure Container Apps](https://github.com/microsoft/vscode-azurecontainerapps)
## API Reference
See [vscode-azureresources-api.d.ts](./docs/vscode-azureresources-api.d.ts) for the full API definition.
See [vscode-azureresources-api.d.ts](https://github.com/microsoft/vscode-azureresourcegroups/blob/main/api/docs/vscode-azureresources-api.d.ts) for the full API definition.
## Terms
terms:
* **Host extension**: Azure Resources extension which exposes the Azure Resources API
* **Host API**: Azure Resources API exposed by the host extension
* **Client extension**: Extension which consumes the Azure Resources API
* **Azure resources view**: Unified view of Azure resources contributed owned by the Azure Resources extension
* **Workspace resources view**: Unified view of workspace resources contributed by client extensions
* **Azure resource**: Any resource that can be represented in the Azure resources view
* **Azure resource**: A resource that can be represented in the Azure resources view.
* **Workspace resource**: Any resource that is located on the local machine, or in the opened workspace.
* **Host API**: Azure Resources API exposed by the host extension
## Document todo list
<!-- ## Document todo list

@@ -303,2 +293,4 @@ big todo:

* FAQ
* Add a section on how to contribute to the Azure resources view
* Add a section on how to contribute to the Workspace resources view

@@ -324,1 +316,2 @@ small todo:

-->
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc