Sanal Tserenov78 downloads1C (BSL) Language Support for Markdown files in Obsidian
[!WARNING] This plugin was created with the help of AI and has not been thoroughly reviewed or tested. It is still a work in progress and may contain bugs. Use it at your own risk, and please report any issues you find.
Syntax highlighting for the 1C:Enterprise built-in language (BSL) in Obsidian code blocks — both in reading mode and in the editor.
1c in any letter case, Cyrillic or Latin. The bsl and os (OneScript) tags are also supported.
Если/If, КонецЕсли/EndIf, Асинх/Async, Ждать/Await, etc.);Сообщить, СтрДлина, Окр, ТекущаяДата, ЗначениеЗаполнено…) and platform types (Массив, Структура, Запрос…);Истина, Ложь, Неопределено, Null literals;| continuation and "" escaping;'20240101', numbers, // and /* … */ comments;#Если Сервер Тогда, #Область) and annotations (&НаСервере, &Перед("Имя"));=, +, *, comparisons, И/Или/Не…) and punctuation;Open Settings → Community plugins → Browse, search for "1C", then install and enable 1C (BSL) Language Support.
main.js and manifest.json from the latest GitHub release.onec-syntax-highlight inside your vault:
<vault>/.obsidian/plugins/onec-syntax-highlight/Paste into a note:
```1c
Процедура Приветствие(Имя = "Мир") Экспорт
Если Не ЗначениеЗаполнено(Имя) Тогда
Имя = "мир";
КонецЕсли;
Сообщить(СтрШаблон("Привет, %1!", Имя)); // комментарий
КонецПроцедуры
```
Requires Node.js 18+:
npm install
npm run build
main.js is a build artifact and is not committed to the repository — the build produces it in the project root. Copy it together with manifest.json into <vault>/.obsidian/plugins/onec-syntax-highlight/ (see the steps above).
The keyword and built-in function lists are based on the 1C language definitions from highlight.js (BSD-3-Clause) and Prism (MIT).
License: MIT.