Code

An inline highlighted piece of code.

Examples

Text with code console.log("styple") in between.

Text with code console.log("styple") in between.

import { Code } from "@styple/design-system";
<Flex css={{ flexDirection: "column", alignItems: "center", gap: "$md" }} >
<Text>Text with code <Code>console.log("styple")</Code> in between.</Text>
<Text>Text with code <Code color="normal">console.log("styple")</Code> in between.</Text>
</Flex>

API Reference

Code

A styled component with props:

Prop Type Default Explanation
colorstring"accent"

Color variant.