Quantcast
Channel: Active questions tagged visual-studio-code - Stack Overflow
Viewing all articles
Browse latest Browse all 97420

Vim or Emacs-like modeline magic support for VSCode

$
0
0

I'm writing a script using Qt's ECMAScript. The files use the extension .qs, which VSCode does not currently have syntax highlighting for. javascript syntax highlighting, however, is plenty pretty to satisfy me.

Is there any way to map .qs to javascript from within the .qs file? This would be similar to File Variables for Emacs or Modeline Magic for Vim.

I know that I can map .qs to javascript in the VSCode settings as described here, but would prefer something that ships with the file.

There's also this extension that seems to achieve this, but I'm curious if there are other options.

Example modelines for both Vim and Emacs:

# vim: set ft=js
// -*- mode: js; -*-

Preferably this would be built into VSCode, but it doesn't look like that is going to happen based on the answer to this issue.

Looking for other hacks or alternatives that people know of!


Viewing all articles
Browse latest Browse all 97420

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>