mirror of
https://github.com/larvit/adf-codec.git
synced 2026-11-16 21:30:25 +01:00
Answer the stability pass: the strip that changed nothing, and the words the body earns
This commit is contained in:
@@ -5,7 +5,7 @@ import { holdsEntityReference } from './entity-references.ts'
|
||||
|
||||
export type LanguageSlot = { info: string; kind: 'fence' } | { kind: 'attribute' } | { kind: 'none' }
|
||||
|
||||
// spec/flavour.md, The CommonMark blocks: the one slot a codeBlock's language rides, both directions.
|
||||
// spec/flavour.md, The CommonMark blocks: the one slot a codeBlock's language rides.
|
||||
export function languageSlot(language: JsonValue | undefined): LanguageSlot {
|
||||
if (language === undefined) return { kind: 'none' }
|
||||
if (typeof language !== 'string' || language === '' || language === carryName) return { kind: 'attribute' }
|
||||
|
||||
Reference in New Issue
Block a user