gitlab-org--gitlab-foss/app/assets/javascripts/ide/lib/languages
2021-01-13 12:10:27 +00:00
..
hcl.js Add latest changes from gitlab-org/gitlab@master 2021-01-13 12:10:27 +00:00
index.js Add latest changes from gitlab-org/gitlab@master 2020-10-07 12:09:12 +00:00
README.md Add latest changes from gitlab-org/gitlab@master 2020-10-07 00:08:24 +00:00
vue.js Add latest changes from gitlab-org/gitlab@master 2020-12-23 12:10:26 +00:00

Web IDE Languages

The Web IDE uses the Monaco editor which uses the Monarch library for syntax highlighting. The Web IDE currently supports all languages defined in the monaco-languages repository.

Adding New Languages

While Monaco supports a wide variety of languages, there's always the chance that it's missing something. You'll find a list of unsupported languages in this epic, which is the right place to add more if needed.

Should you be willing to help us and add support to GitLab for any missing languages, here are the steps to do so:

  1. Create a new issue and add it to this epic, if it doesn't already exist.
  2. Create a new file in this folder called {languageName}.js, where {languageName} is the name of the language you want to add support for.
  3. Follow the Monarch documentation to add a configuration for the new language.
    • Example: The vue.js file in the current directory adds support for Vue.js Syntax Highlighting.
  4. Add tests for the new language implementation in spec/frontend/ide/lib/languages/{langaugeName}.js.
  5. Create a Merge Request with your newly added language.

Thank you!