Skip to content

Commit

Permalink
feat: add support for protobuf (#645)
Browse files Browse the repository at this point in the history
* feat: add protobuf

* docs(changeset): Add protobuf language support
  • Loading branch information
riccardoperra authored Sep 1, 2024
1 parent d63f476 commit 581ee89
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/violet-rabbits-flash.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@codeimage/config': patch
---

Add protobuf language support
18 changes: 18 additions & 0 deletions packages/config/src/lib/base/languages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -734,4 +734,22 @@ export const SUPPORTED_LANGUAGES: readonly LanguageDefinition[] = [
},
],
},
{
id: 'protobuf',
label: 'Protobuf',
color: '#a52a22',
plugin: () =>
Promise.all([
importLegacy(),
import('@codemirror/legacy-modes/mode/protobuf'),
]).then(([cb, m]) => cb(m.protobuf)),
icons: [
{
name: 'Protobuf',
extension: '.proto',
content: () => import('material-icon-theme/icons/proto.svg?raw'),
matcher: /^.*\.(proto)$/,
},
],
},
];

0 comments on commit 581ee89

Please sign in to comment.