diff --git a/.changeset/chatty-rivers-move.md b/.changeset/chatty-rivers-move.md new file mode 100644 index 0000000000..83bdf69012 --- /dev/null +++ b/.changeset/chatty-rivers-move.md @@ -0,0 +1,5 @@ +--- +"gitbook": patch +--- + +Support "objectivec" as alias for Objective C syntax diff --git a/packages/gitbook/src/components/DocumentView/CodeBlock/highlight.ts b/packages/gitbook/src/components/DocumentView/CodeBlock/highlight.ts index 80432f9168..650fbd1f68 100644 --- a/packages/gitbook/src/components/DocumentView/CodeBlock/highlight.ts +++ b/packages/gitbook/src/components/DocumentView/CodeBlock/highlight.ts @@ -136,6 +136,9 @@ const syntaxAliases: Record = { // "Parser" language does not exist in Shiki, but it's used in GitBook // The closest language is "Blade" parser: 'blade', + + // From GitBook App we receive "objectivec" instead of "objective-c" + objectivec: 'objective-c', }; function checkIsBundledLanguage(lang: string): lang is BundledLanguage {