syntax: javascript: recognize also the .mjs extension

The V8 JavaScript-engine developers recommend using this extension:
  https://v8.dev/features/modules#mjs

Also, add the fairly new "JavaScript source" as magic description.

This fulfills https://savannah.gnu.org/bugs/?65334.
Requested-by: Matt Whitlock <gnu@mattwhitlock.name>
This commit is contained in:
Benno Schulenberg 2024-02-20 16:44:42 +01:00
parent eca5856d99
commit f1a04f780a

View File

@ -1,6 +1,7 @@
## Syntax highlighting for Javascript.
syntax javascript "\.js$"
syntax javascript "\.m?js$"
magic "JavaScript source"
comment "//"
# Declarational stuff.