Code

The Code component visually distinguishes inline text as a fragment of computer code.

Code

Usage

import { Code } from "@twilio-labs/match/components";
const Component = () => <Code>ahoy()</Code>;

Props

PropTypeDefaultDescription
variant?CodeVariant'dark''dark', 'light'

Guidelines

About Code

The Code component emphasizes short, inline pieces of computer code such as variable names, commands and function calls. For multiline code samples and bash shell prompts, see the Snippet component.


Examples

Dark

The best way to learn about the Twilio CLI is to simply run the twilio command.

Light

See something that looks interesting? Try running twilio api.