samuelcolvin / jinjahtml-vscode

Syntax highlighting for jinja(2) html templates in vscode
https://marketplace.visualstudio.com/items?itemName=samuelcolvin.jinjahtml
MIT License
135 stars 53 forks source link

Add support for rust files #101

Closed TeFiLeDo closed 2 years ago

TeFiLeDo commented 2 years ago

I added support for rust files.

I tested my changes quickly and they seem to work. However, I have to admit that I don't know anything about VS Code extensions and only replicated what I saw in a few other PRs. I might have missed things that aren't obvious.

TeFiLeDo commented 2 years ago

This would also resolve #100

samuelcolvin commented 2 years ago

thanks so much, I'll make a new release soon.

rimutaka commented 2 years ago

@TeFiLeDo , Adrian, how do you use Jinja with Rust? I'm using Tera and this extension seems to work OK apart from a few small glitches. I'm looking at the source to see if I can fix them myself.

TeFiLeDo commented 2 years ago

I'm not yet using it at all, however I'm planning on generating code using askama or Tera.

As for the glitches you experience, I'm sorry to tell you that I have no idea how to fix them. I only looked at a few other PRs and copied their changes. If rust needs additional work, I don't have the required knowledge.

TeFiLeDo commented 2 years ago

Looking at the issue you filed (#103), I'm not sure if we are talking about the same thing, as you seem to be generating HTML. This pull request adds support for .rs files, so you get syntax highlighting when generating rust code.