Code Line

const greeting = "Hello, Beste!";ts
About this piece

Code Line

One-line code snippet with a monospace pill and a tiny language tag on the right.

Usage

The import and the props worth knowing about, in one place.

import { Code1 } from "@/components/beste/piece/code1";

<Code1
  surface="card"
  bordered={false}
  inverted={false}
  code="const greeting = \"Hello, Beste!\";"
  language="ts"
/>

More Code pieces

View all Code
const user = await fetchUser("42");
greet.ts
export function greet(name: string) {
return `Hello, ${name}!`;
}
 
console.log(greet("Beste"));
Open command palette
⌘K
function greet(name) {
return 'Hi ' + name;
return `Hello, ${name}!`;
}
members.ts
import { Sirius } from '@sirius/sdk'
const client = new Sirius(apiKey)
await client.members.create({ name })
SELECT id, name, email
FROM users
WHERE active = true
ORDER BY created_at DESC
LIMIT 10;