Esc
Documentation
On this page

Props

PropTypeDefaultDescription
label requiredstring | FieldReferenceNoneBlock label
value requiredstring | FieldReferenceNoneCode content
language"python" | "sql" | "text" | FieldReference"text"Syntax language
dataReadonly<Record<string, unknown>>NoneInline data to render as the code block content (alternative to source)

Example

ts
CodeBlock({
  label: "Query",
  value: "SELECT * FROM orders WHERE total > 100",
  language: "sql",
})

View the source on GitHub