Skip to main content
WireKit
Copy for LLM

Code

Inline code component for short snippets that sit within text flow — variable names, paths, commands, identifiers. Renders a <code> element with a tinted background, subtle border, and the design-system monospace font.

For multi-line snippets (commands, route definitions, file contents) use <x-wirekit::code-block> instead.

Live Sandbox

This is a hydrated playground for the component. Toggle "Live preview" on the block below to swap the static HTML render for a real Livewire instance — every prop in the component's sandbox schema becomes an editable form field inside the iframe, so you can try different prop combinations live without writing any local code.

Sandbox
$wirekit

Basic Usage

Inline code in text flow

Run composer require pushery/wirekit to install.

In Headings

Inline code adapts its size relative to the surrounding text — the font size is set in em, so a heading-sized <x-wirekit::code> matches the heading's font size automatically.

Inline code in a heading

Configure config/wirekit.php

Props

Prop Type Default Description
scope string|null null Scoped personalization name

Keyboard Interaction

This component is purely presentational and does not respond to keyboard input.

Design Tokens

Token Used for
--font-wk-mono Monospace font family
--color-wk-bg-muted Background color
--color-wk-text Foreground color
--color-wk-border-subtle Border color
--radius-wk-sm Border radius

See Also

Was this page helpful?

Voting requires cookies or local storage. What we store