diff --git a/README.md b/README.md index fa60e90b528..111eff34225 100644 --- a/README.md +++ b/README.md @@ -315,7 +315,10 @@ See the [CHANGELOG](CHANGELOG.md) file for details. ### Lead Developers * **[Liyas Thomas](https://github.com/liyasthomas)** - *Author* -* **[Caneco](https://twitter.com/caneco)** - *Designer* +* **[John Harker](https://github.com/NBTX)** - *Lead developer* +* **[Andrew Bastin](https://github.com/andrewbastin)** - *Lead developer* +* **[James George](https://github.com/jamesgeorge007)** - *Lead maintainer* +* **[Caneco](https://twitter.com/caneco)** - *Logo and banner designer* ### Testing and Debugging diff --git a/functions/editorutils.js b/functions/editorutils.js new file mode 100644 index 00000000000..c8e14a5f99f --- /dev/null +++ b/functions/editorutils.js @@ -0,0 +1,11 @@ +const mimeToMode = { + "text/plain": "plain_text", + "text/html": "html", + "application/xml": "xml", + "application/hal+json": "json", + "application/json": "json" +} + +export function getEditorLangForMimeType(mimeType) { + return mimeToMode[mimeType] || "plain_text"; +} diff --git a/pages/index.vue b/pages/index.vue index 85fd5938f66..c22b822a419 100644 --- a/pages/index.vue +++ b/pages/index.vue @@ -375,7 +375,7 @@