diff --git a/src/language-html/index.js b/src/language-html/index.js
index e90f51a21..f8a819ae4 100644
--- a/src/language-html/index.js
+++ b/src/language-html/index.js
@@ -21,6 +21,11 @@ const languages = [
since: "1.15.0",
parsers: ["html"],
vscodeLanguageIds: ["html"]
+ },
+ extend: {
+ extensions: [
+ ".mjml" // MJML is considered XML in Linguist but it should be formatted as HTML
+ ]
}
}),
createLanguage(require("linguist-languages/data/vue"), {
diff --git a/tests/html_mjml/__snapshots__/jsfmt.spec.js.snap b/tests/html_mjml/__snapshots__/jsfmt.spec.js.snap
new file mode 100644
index 000000000..57c550ef8
--- /dev/null
+++ b/tests/html_mjml/__snapshots__/jsfmt.spec.js.snap
@@ -0,0 +1,65 @@
+// Jest Snapshot v1, https://goo.gl/fbAQLP
+
+exports[`empty.mjml 1`] = `
+====================================options=====================================
+parsers: ["html"]
+printWidth: 80
+ | printWidth
+=====================================input======================================
+
+=====================================output=====================================
+
+
+================================================================================
+`;
+
+exports[`head.mjml 1`] = `
+====================================options=====================================
+parsers: ["html"]
+printWidth: 80
+ | printWidth
+=====================================input======================================
+
+
+
+
+
+ The green fix eats mango.
+
+
+
+
+ Do
+
+ you like cheese? We do!
+
+
+
+
+
+
+=====================================output=====================================
+
+
+ The green fix eats mango.
+
+ Do you like cheese? We do!
+
+
+
+
+
+
+================================================================================
+`;
diff --git a/tests/html_mjml/empty.mjml b/tests/html_mjml/empty.mjml
new file mode 100644
index 000000000..27a34a57c
--- /dev/null
+++ b/tests/html_mjml/empty.mjml
@@ -0,0 +1 @@
+
\ No newline at end of file
diff --git a/tests/html_mjml/head.mjml b/tests/html_mjml/head.mjml
new file mode 100644
index 000000000..477716530
--- /dev/null
+++ b/tests/html_mjml/head.mjml
@@ -0,0 +1,25 @@
+
+
+
+
+
+ The green fix eats mango.
+
+
+
+
+ Do
+
+ you like cheese? We do!
+
+
+
+
+
diff --git a/tests/html_mjml/jsfmt.spec.js b/tests/html_mjml/jsfmt.spec.js
new file mode 100644
index 000000000..53763df9b
--- /dev/null
+++ b/tests/html_mjml/jsfmt.spec.js
@@ -0,0 +1 @@
+run_spec(__dirname, ["html"]);
diff --git a/tests_integration/__tests__/__snapshots__/support-info.js.snap b/tests_integration/__tests__/__snapshots__/support-info.js.snap
index afa4ed067..7c444ae28 100644
--- a/tests_integration/__tests__/__snapshots__/support-info.js.snap
+++ b/tests_integration/__tests__/__snapshots__/support-info.js.snap
@@ -906,7 +906,8 @@ exports[`CLI --support-info (stdout) 1`] = `
\\".inc\\",
\\".st\\",
\\".xht\\",
- \\".xhtml\\"
+ \\".xhtml\\",
+ \\".mjml\\"
],
\\"linguistLanguageId\\": 146,
\\"name\\": \\"HTML\\",