deckgo/deckdeckgo

studio: do not fetch code language list at runtime to improve performance

peterpeterparker opened this issue · 0 comments

Affected part of DeckDeckGo

  • Studio (online editor)

Feature Description

Once thing I noticed, when I wanted to add code blocks, and wanted to change the language in the options dialog, the dialog options it takes some time to open, and if you click it 3 times, it will open 3 dialogs.

To improve this behavior, we should replace the fetching of the languages at runtime and include the list of code language in the bundle.

Use Case

Improve performance

Code

This service can be improved or replaced.

The important thing to do is to remove the fetch and use a list of languages. Such list already exists in our Web Component highlight code therefore we can use this definition.

If it is not exported by the component, it can be exposed.