panoply / vscode-liquid

💧Liquid language support for VS Code
https://marketplace.visualstudio.com/items?itemName=sissel.shopify-liquid
Other
173 stars 22 forks source link

Emmet shortcuts not working in HTML #117

Closed davidwarrington closed 1 year ago

davidwarrington commented 2 years ago

I can't use emmet shortcuts to generate HTML. For example previously I could type .my-element and then press tab to generate

<div class="my-element"></div>

This still works inside .html files so I'm assuming the 3.* update is the cause.

panoply commented 2 years ago

You'll need to associate this in workspace:

{
  "emmet.includeLanguages": {
    "liquid": "html"
  }
}

We can infer these settings automatically in the defaults, do you think it would be better to do this?

davidwarrington commented 2 years ago

That worked a charm, cheers! It's been such a long time since I've had to do that for anything.

I think it would be sensible to make a default as I'm unaware of any contexts where you'd use Liquid outside of HTML. That being said I don't know how many people actually use emmet abbreviations. If not a default perhaps a note could be added to the extension docs, as I'd guess this won't be the last time you're asked about this.

panoply commented 2 years ago

Good point. I'll add it in v3.1.0 to defaults.

panoply commented 2 years ago

Alright, co-authored this one and it will be available on the default. Included Liquid CSS and Liquid SCSS snippets. Following extensions will automatically have emmet available:

panoply commented 1 year ago

Shipped https://github.com/panoply/vscode-liquid/pull/110