vscode-apimanagement icon indicating copy to clipboard operation
vscode-apimanagement copied to clipboard

What is the proper language for highlighting and formatting APIM Policy files?

Open Corendiel opened this issue 1 year ago • 4 comments

Hello,

I'm looking for an Extension to Highlight policy files and format them properly in Visual Studio Code. I tried Razor, HTML, XML, ASP.Net Razor, and HTML (C#), and none worked properly. It has issues with the C# expressions and named values in {{ }}.

Visual studio code recommends C# extension with ASP.Net Razor Language. Even the APIM Portal code editor doesn't highlight code properly.

What do you recommend?

Corendiel avatar Mar 23 '23 21:03 Corendiel

Ever find anything useful? After installing the extension an "apim-policy" language option is available, but using it gets no highlighting, validation, or auto completion. Any XML highlighter trips on things like unescaped quotes in the c# expressions. As far as auto completion, the best I've found is to have an AI code assistant.

DannyMeister avatar Oct 17 '23 16:10 DannyMeister

Yeah, apim policy syntax checking is very desireable!

Camios avatar Mar 28 '24 06:03 Camios

Any update on this, looking the same. The code doesn't look well in vs code at all.

Any luck?

sterankin avatar Apr 24 '24 22:04 sterankin

Hi, any updates on this?

itssKrish avatar Jul 09 '24 14:07 itssKrish