autorest.typescript
autorest.typescript copied to clipboard
[mgnt] Type choice name is not matched between definition and reference if name is all uppercase
Type choice name is not matched between definition and reference if name is all uppercase After generation the definition of this type would be:
export type Sku = string;
But in the reference the type would be like:
/** Device Update Sku */
sku?: SKU;
So we have below hint in VS code:
Cannot find name 'SKU'. Did you mean 'Sku'?
Exported type alias 'Account' has or is using private name 'SKU'.
Refer SKU
enum definition in this swagger: https://github.com/Azure/azure-rest-api-specs/blob/78665b44d4b9295e56664193fc3baa9e0526d15d/specification/deviceupdate/resource-manager/Microsoft.DeviceUpdate/preview/2022-04-01-preview/deviceupdate.json#L1335