import {InlineCode} from '@primer/react-brand'Usage
Use inline code for short code fragments such as commands, filenames, API names, configuration keys and values.
Examples
Default
Loading
In a heading
Loading
Wrapping
InlineCode wraps by default to prevent long fragments from overflowing their container. Use wrap={false} only for
slash commands that must remain together and have a low character count.
Loading
Component props
| Name | Type | Default | Description |
|---|---|---|---|
wrap | boolean | true | Controls whether the code fragment can wrap. |
InlineCode renders a native code element and accepts its standard HTML attributes.