Code

Displays code inline in text.

It implements the <code> element.

Props

Use any valid <code> props.

Examples

Non-HTML code.
import { Code } from 'device-agnostic-ui'

<Code>window</Code>
window
Code in a link.
import { Code, LinkText } from 'device-agnostic-ui'

<LinkText href="https://developer.mozilla.org/en-US/docs/Web/API/Window">
  <Code>window</Code>
</LinkText>
HTML code.
import { Code } from 'device-agnostic-ui'

<Code>{'<strong>'}</Code>
<strong>

Tags